mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-21 21:38:00 +01:00
Simplify the application appicon creation
This patch removes all the appicon stuff from the application creation to the appicon creation. Now, the application only calls one function (create_appicon_for_application()) and this function do all the work. The function do the same code than the code before this patch, but the only change is that the "if" test to check if the appicon was found in the docks now is negated, removing the return and doing the appicon_save inside the function. Finally, the old makeAppIconFor is now create_appicon_for_application().
This commit is contained in:
committed by
Carlos R. Mafra
parent
97d7c32184
commit
70c9208e40
@@ -141,17 +141,7 @@ WApplication *wApplicationCreate(WWindow * wwin)
|
||||
/* application descriptor */
|
||||
XSaveContext(dpy, main_window, wAppWinContext, (XPointer) wapp);
|
||||
|
||||
/* First try to create an icon from the dock or clip */
|
||||
create_appicon_from_dock(wwin, wapp, main_window);
|
||||
|
||||
/*
|
||||
* In case it was not found in the dock, make it from scratch.
|
||||
* Note: makeAppIconFor() returns early if wapp->app_icon exists
|
||||
*/
|
||||
makeAppIconFor(wapp);
|
||||
|
||||
/* Save the app_icon in a file */
|
||||
save_appicon(wapp->app_icon, False);
|
||||
create_appicon_for_application(wapp, wwin);
|
||||
|
||||
return wapp;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user