Some icons (modern settings, jump-list tasks) are monochrome, basically
they are defined just by alpha channel.
Thus they can be displayed in any color (white is default).
Since these icons are white by default, they look nice on dark
backgrounds. But they are not very visible on light backgrounds.
Thus the idea is to 'colorize' such icon using color of corresponding
text item. That way they will always have proper color.
Fixes#466.
Use `OnToastActivate` to display update dialog if user clicked on toast
during `update.exe` life-time.
Process messages for some time after displaying toast.
Otherwise toast may be not displayed at all.
Use toast notification to announce new update on modern Windows
versions.
The advantage of toasts is that they look more natural and they are
persistent. So one can find the information about new update in action
center even after notification timed out.
Task jump-list items for modern apps require special handling.
First of all they don't provide icon directly.
Icon location is stored in `PKEY_AppUserModel_DestListLogoUri` property.
And then has to be resolved for given application package.
Next, context menu of provided `IShellLink` item doesn't seem to be able
to start actual link target.
Thus we need to obtain context menu of target item.
Fixes#375.
Link to modern application will be treat as modern application itself.
This fixes jump-lists and invert metro color option on modern apps pinned
to start menu.
Based on `HostId`:
* {7E0522FC-1AC4-41CA-AFD0-3610417A9C41}
execute `shell:::{PageId}`
* {12B1697E-D3A0-4DBC-B568-CCF64A3F934D}
execute command in `DeepLink`
Currently it was used only in some cases (like Programs/Apps folder).
It will be more consistent to respect the setting for all folder
items.
Fixes#436.
Adds virtual shell folder that contains items representing modern settings parsed from
`%windir%\ImmersiveControlPanel\Settings\AllSystemSettings_{253E530E-387D-4BC2-959D-E6F86122E5F2}.xml`.
It can be accessed via `shell:::{82E749ED-B971-4550-BAF7-06AA2BF7E836}` (in explorer).
Item in folder will open given setting page in `Settings` application.
Some projects do register COM server in Debug/Release sonfigurations.
We should do it with per-user redirection so that there is no need to
run elevated Visual Studio.
This has no effect on COM server registering in installed Opne-Shell.
It is related only to local development.
When `Invert Metro icon color` is enabled `Open-Shell` needs to
distinguish full color icons from monochromatic ones.
Color icons are displayed normally. Monochromatic ones are displayed
inverted (original background becomes transparent and foreground will
get Metro accent color).
Metro icon is loaded from Metro app resources (usually PNG image) as
bitmap with premultiplied alpha channel.
This causes monochromatic image to essentially become grayscale (because
RGB values are multiplied with alpha channel value).
Function `DetectGrayscaleImage` is used to distinguish such images.
Unfortunatelly if original image is grayscale (such as new Windows
Terminal icon) it is recognized as monochromatic and thus inverted.
To prevent this we will take into account also alpha channel in
`DetectGrayscaleImage`.
In monochromatic images alpha channel value will be the same as the rest of
channel values.
For color images alpha channel value will be different than other
channel values.
Fixes#364.
Delete confirmation dialog may be (partially) hidden behing start menu.
As a result the dialog may be not accessible because start menu(s) are
displayed as top-most windows.
Thus when executing menu command we will make menu(s) non-topmost. So that
other windows can be drawn on top of menu(s).
Fixes#257