Original fix introduced in 528d15 was not correct.
The problem is that `SystemParametersInfo` uses DPI that current session
started with.
We should use `SystemParametersInfoForDpi` (available since Win10 1607)
that returns properly scaled font size.
Fixes#1110
If skin doesn't specify font to be used (such as `Classic Skin`) we will
use default system font (used for menus).
But we didn't scale the font size according to DPI.
This commit will fix that.
Fixes#1110
Windows 11 Insider builds started to register global shell hotkey for
Win key (and Ctrl+Esc) that are used to trigger start menu.
The problem is that it is not (easily) possible to intercept messages
about these hotkeys.
Thus we will unregister them during init and install hook that will
prevent their further registration.
Fixes#1165
Windows updates are applied on shutdown/reboot no matter of flags used
in ExitWindowsEx (or InitiateShutdown).
Windows start menu shutdown code handles updates in special way.
If there are updates prepared and shutdown/reboot is selected it will
use `UpdateSessionOrchestrator` object to dismiss updates and carry out
the command.
We will now do similar thing.
Fixes#1250
Shutdown privilege can be removed from users (in Local Security Policy settings).
This will remove it also from limited admin.
Thus admin will be unable to shutdown machine (because Explorer runs as
limited admin by default).
In such case we will attempt to do silent elevation and proceed with
shutdown using `SystemSettingsAdminFlows.exe` helper.
Fixes#1015
Windows start menu uses it that way too.
ExitWindowsEx is also annotated as legacy API in SDK.
We will also put shutdown handling into separate function, so that we
have it handled at one place (will make further changes easier).
Standard API for sleep (`SetSuspendState`) seems to do nothing on
systems with connected standby.
Windows start menu calls `NtPowerInformation(ScreenOff)` on such systems instead.
This is implemented in `shutdownux!ShutdownViewModel::_InitiatePowerTransition` function.
Fixes#719
With the option enabled keyboard accelerators will be triggered only if Alt key
is pressed as well.
This is how typical Windows keyboard accelerators work, to avoid
confusion with regular key presses.
Fixes#117
It will control whether keyboard accelerators are used in start menu.
Disabling it can be helpful for people that tend to hit some accelerator by mistake.
Fixes#447
Start menu window was activated early in the process of its creation.
This means it was receiving input before focus was set to search bar.
And that may have lead to unwanted use of keyboard accelerators.
We need to make sure that window is activated (receives input) only once
focus was set to search box.
Fixes#1068
Windows started to add newer version of settings to settings description
file. These have the same description as older settings, but use
different parameters.
Unfortunately old settings are still present.
This causes our modern settings folder to contain duplicates.
And also we tend to use older setting definitions that no longer work
properly.
Thus we will de-duplicate parsed settings and try to keep newer ones
(that should work better).
New settings tend to have numeric suffix, so we will keep those with
biggest suffix.
Fixes#1031
Defender settings on Win11 use indirect strings in form:
`@{Microsoft.SecHealthUI_8wekyb3d8bbwe?ms-resource://Microsoft.SecHealthUI/Resources/DisplayName}`
`SHLoadIndirectString` is unable to load such indirect string, because it expects full
package name (instead of package family name).
In such case we will convert package family name to full name and try again.
- Taskbar is now handled by taskbar.dll, so we need to hook APIs there
- TaskList window (MSTaskListWClass) is not visible so we need to
hook messages of its parent TaskBand window (MSTaskSwWClass)
Fixes#1230
This changes default value of `Show next to taskbar (when the taskbar is vertical)` setting to `enabled`.
It makes more sense to have menu next to vertical taskbar than to
overlap it (and hide taskbar buttons).
Windows start menu does it like that too.
It is not a program that user will use explicitly.
No need to show it in the list even if Windows tracks it as frequent
program for some reason.
Fixes#1164
When taskbar is hidden its window is moved off the screen (except for
few pixels at border). It may happen that the taskbar window actually
spans to another monitor (though still not visible).
MonitorFromWindow API may thus return different monitor handle than the
one visible taskbar is on.
We will use GetTaskbarPosition function that correctly identifies taskbar's
monitor by checking rectangle of visible taskbar.
Fixes#908
- handling of `Taskbar alignment` setting (left/center)
- start menu position is based on position of start button
- mouse clicks to original button now work properly (without triggering original menu)
- custom button is properly positioned
- Win+X works properly
Debug StartMenuDLL used to not find skins when put to Open-Shell
installation folder.
Now it will try to look for skins in default location (Skins folder in
the same folder as DLL) and use alternative (Skins folder one level up)
if not present.
We are storing color settings in BBGGRR format (for historical reasons).
This may be confusing for people that are used to (more widely used) RRGGBB format.
Thus we will present color settings in RRGGBB format when editing.
We will still use BBGGRR format for those settings internally. To
maintain backward compatibility with existing settings stored in
registry/xml.
Also setting descriptions now contain hint about expected color format.
This way it should be more clear what values `Open-Shell` expects.
Fixes#82, #1141.
x64 version of pdbstr doesn't work (because of missing __CxxFrameHandler4 on Windows Server 2019).
Fortunately it seems that x86 version works well, so we can use that one.
We are now deploying official builds from master to Github releases page
(as Prerelease).
So we should get these build from there.
This is also related to AppVeyor's rather tight download limits that
make it quite challenge to obtain nightly builds.
- Updated "release" badge to point to latest release version directly
- Removed "Latest nightly build" link as nightly builds are now part of standard Releases page
(Modern) Settings are more and more important in Windows 10,
so it makes sense to show them above Control Panel.
This changes only defaults, users will be still able to order start menu
items as they like.
Fixes#23.
`Open-Shell` hooks `SHFillRectClr` (ordinal 197) API from `shlwapi.dll`
in order to be able to customize taskbar.
The API is hooked even if taskbar customization is disabled in `Open-Shell` (default).
`WindowBlinds` hooks the same API so this is causing clashes between
both programs.
In fact `Open-Shell` hooks later which makes `WindowBlinds` hook to be
completely ignored.
The solution would be to hook only if taskbar customization is enabled.
This way `Open-Shell` should be more compatible with other customization
tools in default state.
Fixes#433.
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.