From: Artem B. <ar...@v2...> - 2004-06-22 19:48:11
|
Artem Baguinski wrote: > dear all > > i'm working on adding a new feature to rox tasklist and i wanna hear > your reaction / advice. > > the idea: by dragging a task button from a tasklist into filer one can > easily create rox wrappers to running applications. say i start mozilla > from xterm, open my home directory and drag the mozilla button from > tasklist into it. tasklist comes up with a name, icon, AppRun wrapping > mozilla. > > status: > > 1. i had to first modify libwnck to support task_drag_start and > task_drag_data_get callbacks -> this part is mostly finished, i only > have to add some cleanups and handle reassigning the callbacks correctly > (not that anybody'll ever want to reassign the callbacks, but who am i > to foresee) > > 2. then i needed to modify tasklist to supply these callbacks, which i > did. I used GtkSavebox as a reference for implementing XDS dnd. At the > moment the callback: > (a) comes up with a nice name (using wnck_application_get_name) and > creates a directory with such name > (b) discovers the command line that was used to start the application > and creates AppRun that looks like: "#!/bin/sh ; exec that-command-line" (c) creates .DirIcon using gdk_pixbuf received with wnck_application_get_icon() that's the icon you see in the taslklist - some applucations don't provide one (or libwnck fails to retrieve it). > i don't wanna publish the patch in its current state (and i still have > to come up with a .DirIcon which i hope to accomplish later today). i've reluctantly uploaded the patch + modified version of the libwnck here: http://www.artm.org/pub/hacks/rox/tasklist/ the patch is against version 0.5 of tasklist from http://sheen.fallingsnow.net/Software/ test and enjoy ;-) i'd appreciate any better ideas about searching for icon or command line to go into AppRun. cheers, artm |