On Mon, 11 Jun 2012 at 23:28:01 +0200, Rodolfo kix Garcia wrote:
> 
> I did this experimental patch. I sent it compressed because I want
> to explain it (using my poor english).

It's not a good idea to send compressed patches. Less people will see
it.
 
> The idea of this patch is break the current icon creation. Now, when
> a new aplication is launched, the function wApplicationCreate is
> called, then it search an icon (extractIcon function), then check if
> the application needs an icon (no_appicon set) and then create the
> application icon, save it (again??) and paint it.
> 
> IMO this is an error. The application should create the icon
> allways, then save it (if was not previously created), and then
> check if the application needs appicon (no_appicon set) then paint
> or not it.

I agree with you.

> To do it, I created two patches. The first patch breaks the
> dependency between create+paint an icon. Now, if we create an icon,
> we call "wIconCreate". If we needs paint it, then calls
> "paint_icon".

Your patch does not seem to quite match your description, you removed the
paint_icon() call from wIconUpdate() and added it right after 
all 11 calls to wIconUpdate(). So it looks like this is related to
"update" and not "create".

But regardless of that, I think we should leave the paint_icon() call
inside wIconUpdate(). There is no downside and we avoid the repetition
(11 times!) of those lines right after wIconUpdate().

> The second patch do the main work. The application is created, calls
> to wApplicationCreate, create the icon, save it, check if no_appicon
> is needed, then calls paint_appicon.
> 
> Now, the icon in the switchpanel shows the icon, always, and the
> icon in the appicon is the the same icon.

The second patch is really nice! Especially the removal of extractIcon()
and the extra wAppIconSave().

But I did not understand why you still want to create the appicon
even if no_appicon is set. Isn't that a waste of energy? What am I
missing?


-- 
To unsubscribe, send mail to wmaker-dev-unsubscr...@lists.windowmaker.org.

Reply via email to