[gpm] Fixing icon compatibility [Was: Re: [Bug 617529] ]

Here's a patch that explicitly provides a prioritized list of icon names, including the new symbolic names as well as the previous names from GNOME_POWER_MANAGER_2_30_1.  This restores compatibility with the older icon names without adding any additional preferences or symbolic links.

The filename is now built up as a semicolon-separated list, prioritized from first to last.  This list is split on ";" into an array of strings, which is then passed to g_themed_icon_new_from_names() to assist in choosing the proper name.  The first name for which an icon exists will be chosen.

This makes the icon naming code more regular across devices, thus introducing a few minor differences in corner-cases from previous implementations.  In most cases, these corner-cases should be irrelevant.  Without having seen the icon spec, I was only able to try to honor the apparent intentions of the pre-existing code.  The "-symbolic" suffix isn't added to all possible names, as was allowed in the previous implementation. 

Things to pay attention to in the code review:
1) What is the intended prioritization of names?  (I tried to reflect existing code rather than make it simplest.  Is the "use_symbolic" option still desired?)
2) Which icon names need the "-symbolic" suffix?  Please remove those that aren't needed, and add any that are needed which might be missing.


Attachment: 0001-Added-explicit-fallback-priority-lists-for-icon-nami.patch
Description: Binary data

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]