Commit Graph

2503 Commits

Author SHA1 Message Date
Josh Soref
054ab88ef1 spelling: rendering
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:03 -04:00
Josh Soref
9c6c7a82cb spelling: registry
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:59 -04:00
Josh Soref
c72ed77632 spelling: recommended
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:54 -04:00
Josh Soref
6e6ae6f1d3 spelling: precedes
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:49 -04:00
Josh Soref
706bce07e5 spelling: parameters
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:45 -04:00
Josh Soref
ee6a9b3b6b spelling: occurred
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:41 -04:00
Josh Soref
ade22bf48c spelling: modifier
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:37 -04:00
Josh Soref
3bc0405715 spelling: milliseconds
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:33 -04:00
Josh Soref
c2114d8e3b spelling: maximum
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:27 -04:00
Josh Soref
6c0efef967 spelling: intentionally
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:23 -04:00
Josh Soref
b0a584d5ee spelling: initialize
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:19 -04:00
Josh Soref
27bb96b61c spelling: inferred
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:14 -04:00
Josh Soref
034da586c8 spelling: explicitly
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:09 -04:00
Josh Soref
4961601b84 spelling: exception
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:41:01 -04:00
Josh Soref
aa19430d52 spelling: directory
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:40:48 -04:00
Josh Soref
a161a94241 spelling: correctly
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:40:44 -04:00
Josh Soref
791b0cb904 spelling: consistency
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:40:36 -04:00
Josh Soref
37dbcb91cd spelling: coming
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:40:32 -04:00
Josh Soref
1888a4cf99 spelling: catalog
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:39:18 -04:00
Josh Soref
e68999ea0d spelling: adjacent
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:39:10 -04:00
Clint Rutkas
98cb5f2e55
Merge pull request #7686 from microsoft/lego/hb_2939_20201030110544911
LEGO: Pull request from lego/hb_2939_20201030110544911 to master
2020-10-30 09:10:07 -07:00
Clint Rutkas
ad52061c50
Merge pull request #7660 from microsoft/lego/hb_2939_20201029230554135
LEGO: Pull request from lego/hb_2939_20201029230554135 to master
2020-10-30 09:09:24 -07:00
Clint Rutkas
6f67fa533a
Merge pull request #7630 from microsoft/lego/hb_2939_20201029110538004
LEGO: Pull request from lego/hb_2939_20201029110538004 to master
2020-10-30 09:08:57 -07:00
Seraphima Zykova
4a7ce82688
[Localization] Unreachable input box in FancyZones Editor fix. (#7689) 2020-10-30 19:00:33 +03:00
Ivan Stošić
df28473326
[FancyZones] Use Direct2D to draw (#7547)
* Started work

* Good progress on D2D

* Visuals are good, functionality - almost there

* Opacity fix

* Animation works, WM_PAINT still doesn't

* Simplify code, remove flashZones, remove unused code

* Kinda works, but it's a bit laggy

* Works great, but needs refactoring/performance improvements

* Move code from .h to .cpp

* Polished the functionality

* Fix issue with changing monitors

* Rebase fix

* Finalize PR before review

* Couple two members of ZoneWindowDrawing

* Also request a low latency lock when hiding the zone window

* Move textFormat and textBrush out of the loop

* Thread-safe initialization

* Rebase fix: zone numbers

* Make zone borders crispy

* Fix offsets

* Another rebase fix

* Fix DPI bug
2020-10-30 16:25:56 +01:00
stefansjfw
181db8c40a
Enable closing Edit Canvas Layout and Edit Grid Layout windows by pressing Esc button (#7643) 2020-10-30 16:25:27 +01:00
csigs
a87dabda1c LEGO: check in for master to temporary branch. 2020-10-30 11:05:45 +00:00
Clint Rutkas
c37d08c475
Merge pull request #7622 from microsoft/dev/crutkas/helpLocWithComments
Addressing loc team feedback
2020-10-29 22:33:34 -07:00
Clint Rutkas
5417afc623
Merge pull request #6788 from microsoft/dev/crutkas/buildFarmVersioningTake3
Getting version numbers set by the build farm
2020-10-29 20:24:27 -07:00
Clint Rutkas
6d60249fd2
Update Resources.resx 2020-10-29 20:23:20 -07:00
Avneet Kaur
ec8ead8183
[fxcop] Wox.Infrastructure (#7590)
* CA1052: Static holder types should be Static or NotInheritable

* CA1041: Provide ObsoleteAttribute message

* CA1062: Validate arguments of public methods

* CA1304: Specify CultureInfo / CA1305: Specify IFormatProvider / CA1307: Specify StringComparison for clarity

* CA1802: Use Literals Where Appropriate

* CA1820: Test for empty strings using string length

* CA1707: Identifiers should not contain underscores

* CA1805: Do not initialize unnecessarily.

* CA1822: Mark members as static

* CA2227: Collection properties should be read only

* CA1054: URI parameters should not be strings

* CA1031: Do not catch general exception types

* CA1060: Move P/Invokes to NativeMethods class

* CA1308: Normalize strings to uppercase

* CA2000: Dispose objects before losing scope / CA2234: Pass System.Uri objects instead of strings

* CA2234: Pass System.Uri objects instead of strings

* CA1044: Properties should not be write only

* CA1716: Identifiers should not match keywords

* CA2007: Do not directly await a Task

* CA2007: Do not directly await a Task (Suppressed)

* CA5350: Do Not Use Weak Cryptographic Algorithms (Suppressed)

* CA1724: Type names should not match namespaces (renamed Settings.cs to PowerToysRunSettings.cs)

* CA1033: Interface methods should be callable by child types (Added sealed modifier to class)

* CA1724: Type names should not match namespaces (Renamed Plugin.cs to RunPlugin.cs)

* CA1724: Type names should not match namespaces (Renamed Http.cs to HttpClient.cs)

* CA5364: Do not use deprecated security protocols (Remove unused code)

* Enabled FxCopAnalyzer for Wox.Infrastructure

* fixed comment

* Addressed comments

- Changed Ordinal to InvariantCulture
- Added comments
- Removed unused obsolete code
- Removed unused method (CA2007: Do not directly await a Task)

* Addressed comments - fixed justification for CA1031 suppression

* Addressed comments - Fixed justification for CA1031 suppression in Wox.Core/Wox.Plugin
2020-10-29 17:52:35 -07:00
csigs
49d7f90c99 LEGO: check in for master to temporary branch. 2020-10-29 23:05:54 +00:00
Divyansh Srivastava
5015642b6d
[PT Run] Remove duplicated dll's from Plugins (#7617)
* Added copy local false for project references of plugins

* Remove infra and plugin dll from PT Run plugins
2020-10-29 14:46:09 -07:00
Luthfi Mawarid
215c353dee
[fxcop] Settings UI (#7559)
* Remove redundant default initializations

* Implement IDisposable in HotkeySettingsControl

* Mark classes and methods as static

* Move Interop.ShowWindow to NativeMethods class

* Fix string-related warnings

* Remove unused argument for KeyEventHandler

* Log caught general exceptions

* Use safe navigation operator for null argument checks

* Suppress CA2007 warnings and enable FxCop

* Suppress warning for unused event handler params

* Use TryParse in ImageResizerPage

* Use ConfigureAwait(false) for CA2007
2020-10-29 14:24:16 -07:00
Arjun Balgovind
06cd9409e9
Move Focus to Type button in new row on Adding a remap (#7586) 2020-10-29 13:16:52 -07:00
Alekhya
fdffe20c0b
Display Drive detection warning only for multiple drives (#7589)
* indexer drive detection helper code to not show the warning for a single drive

* removed interface from the namespace due to stylecop

* removed interfac which no longer exists

* filter out only fixed drives in the system and ignore the removable drives

* changed text to not all files are indexed, from not all drives are idnexed

* add additional info in the comment
2020-10-29 10:38:15 -07:00
csigs
365a1808c0 LEGO: check in for master to temporary branch. 2020-10-29 11:05:38 +00:00
Clint Rutkas
5ac30cec73
Merge pull request #7620 from microsoft/lego/hb_2939_20201028230559693
LEGO: Pull request from lego/hb_2939_20201028230559693 to master
2020-10-28 21:00:05 -07:00
Avneet Kaur
2e5b6df3a7
Removed Wox.CrashReporter folder since it is not being used anywhere (#7591) 2020-10-28 17:58:09 -07:00
Clint Rutkas
a25cc12c67 loc team feedback 2020-10-28 16:59:29 -07:00
Clint Rutkas
6ebea75f87 loc team feedback 2020-10-28 16:51:30 -07:00
Clint Rutkas
eee5b0d231 adding comments for Rename based on loc team q's 2020-10-28 16:47:52 -07:00
Clint Rutkas
24b7748834 addressing kbm loc team feedback q 2020-10-28 16:44:34 -07:00
Clint Rutkas
68cc4f190c addressing feedback 2020-10-28 16:42:23 -07:00
Clint Rutkas
d3fa1f5be7 addressing loc team feedback 2020-10-28 16:40:50 -07:00
Clint Rutkas
e81dfea600 Addressing comments from https://ceapex.visualstudio.com/CEINTL/_workitems/edit/325394 2020-10-28 16:36:26 -07:00
Clint Rutkas
edaf0fcd2c Addressing color comment issue for light being possible weight vs color 2020-10-28 16:33:00 -07:00
Clint Rutkas
3e059aac56 Adding in FancyZone comments to help with localization 2020-10-28 16:29:01 -07:00
Clint Rutkas
13b0c62ecd shell main does not exist 2020-10-28 16:10:29 -07:00
csigs
70f78c3189 LEGO: check in for master to temporary branch. 2020-10-28 23:06:00 +00:00
Clint Rutkas
8f12973c84
Merge pull request #7612 from microsoft/lego/hb_2939_20201028172704848
LEGO: Pull request from lego/hb_2939_20201028172704848 to master
2020-10-28 13:50:11 -07:00
Clint Rutkas
5ca11f3eac
Merge pull request #7592 from microsoft/lego/hb_2939_20201027230544851
LEGO: Pull request from lego/hb_2939_20201027230544851 to master
2020-10-28 13:49:41 -07:00
Clint Rutkas
b00e5008af
Merge pull request #7609 from microsoft/lego/hb_2939_20201028145308375
LEGO: Pull request from lego/hb_2939_20201028145308375 to master
2020-10-28 12:50:33 -07:00
Clint Rutkas
b8069ce657
Merge branch 'master' into lego/hb_2939_20201027230544851 2020-10-28 12:47:53 -07:00
Clint Rutkas
29ba06739a removing SQLite 2020-10-28 12:38:40 -07:00
Clint Rutkas
9db53461a4 winapp driver 2020-10-28 12:35:41 -07:00
Clint Rutkas
3d53e80532 additional items 2020-10-28 12:24:42 -07:00
Clint Rutkas
40b0a8c127 Updated Fody, PropertyChanged.Fody, Mono.Cecil 2020-10-28 12:18:29 -07:00
Clint Rutkas
965f3813b2
Merge pull request #7574 from microsoft/lego/hb_2939_20201027110546671
LEGO: Pull request from lego/hb_2939_20201027110546671 to master
2020-10-28 12:09:08 -07:00
Clint Rutkas
97a51fc2a9
Merge pull request #7546 from microsoft/lego/hb_2939_20201026110534010
LEGO: Pull request from lego/hb_2939_20201026110534010 to master
2020-10-28 12:08:31 -07:00
Alekhya
3a7fc33943
added a main landmark to all settings pages (#7568) 2020-10-28 11:10:08 -07:00
csigs
8a006d27ca LEGO: check in for master to temporary branch. 2020-10-28 17:27:07 +00:00
csigs
3f45a521a0 LEGO: check in for master to temporary branch. 2020-10-28 14:53:13 +00:00
ivan100sic
39982f1eec Fix DPI bug 2020-10-28 15:50:42 +01:00
ivan100sic
3ede935949 Another rebase fix 2020-10-28 14:30:17 +01:00
ivan100sic
9a60892b68 Fix offsets 2020-10-28 14:23:32 +01:00
ivan100sic
10052a6d7e Make zone borders crispy 2020-10-28 14:23:32 +01:00
ivan100sic
9fd8d831ca Rebase fix: zone numbers 2020-10-28 14:23:32 +01:00
ivan100sic
bb8ee18a59 Thread-safe initialization 2020-10-28 14:23:32 +01:00
ivan100sic
6c05d116a0 Move textFormat and textBrush out of the loop 2020-10-28 14:23:32 +01:00
ivan100sic
d5ef0b1330 Also request a low latency lock when hiding the zone window 2020-10-28 14:23:32 +01:00
ivan100sic
d09e03d7f2 Couple two members of ZoneWindowDrawing 2020-10-28 14:23:32 +01:00
ivan100sic
191c5c3b37 Finalize PR before review 2020-10-28 14:23:32 +01:00
ivan100sic
51faca5b69 Rebase fix 2020-10-28 14:23:32 +01:00
ivan100sic
3b1a70c10a Fix issue with changing monitors 2020-10-28 14:23:32 +01:00
ivan100sic
1390bf271f Polished the functionality 2020-10-28 14:23:32 +01:00
ivan100sic
97ee0205e9 Move code from .h to .cpp 2020-10-28 14:23:31 +01:00
ivan100sic
ad4a6b3386 Works great, but needs refactoring/performance improvements 2020-10-28 14:23:01 +01:00
ivan100sic
0925b479c2 Kinda works, but it's a bit laggy 2020-10-28 14:23:01 +01:00
ivan100sic
f7d3c20648 Simplify code, remove flashZones, remove unused code 2020-10-28 14:23:00 +01:00
ivan100sic
92e8a84a4e Animation works, WM_PAINT still doesn't 2020-10-28 14:20:57 +01:00
ivan100sic
f637cd3202 Opacity fix 2020-10-28 14:20:57 +01:00
ivan100sic
a022b2231f Visuals are good, functionality - almost there 2020-10-28 14:20:57 +01:00
ivan100sic
0c544409dd Good progress on D2D 2020-10-28 14:20:56 +01:00
ivan100sic
92a3ff9b2a Started work 2020-10-28 14:20:08 +01:00
csigs
b7bcd4484a LEGO: check in for master to temporary branch. 2020-10-27 23:05:45 +00:00
Alekhya Reddy
4394491292 resolved merge conflicts and validated that it works as expected 2020-10-27 09:39:22 -07:00
Clint Rutkas
fe32e10dc1
Merge pull request #7565 from microsoft/lego/hb_2939_20201026230523649
LEGO: Pull request from lego/hb_2939_20201026230523649 to master
2020-10-27 09:21:34 -07:00
Arjun Balgovind
03ea90dced
Select all text in Target App textbox on getting focus (#7566) 2020-10-27 09:14:00 -07:00
Arjun Balgovind
d7912e1e12
Added tooltips for Add and Delete buttons (#7564) 2020-10-27 09:13:39 -07:00
Niels Laute
c99fbe54bd Fix conflict 2020-10-27 15:48:15 +01:00
Niels Laute
3bd6e787ab
Merge branch 'master' into users/niels9001/settings-incorrecttheminglabels 2020-10-27 12:11:16 +01:00
csigs
1758449b51 LEGO: check in for master to temporary branch. 2020-10-27 11:05:48 +00:00
Niels Laute
9c3c5725af
Merge pull request #7261 from microsoft/users/niels9001/settings-accesbilitynarratorsupportforshortcutcontrol
[Settings] Added improved narrator support for custom shortcut control
2020-10-27 12:00:04 +01:00
Avneet Kaur
931fd66f66
[fxcop] Fixes for Wox.Plugin (3of3) - enable FxCop Analyzer (#7465)
* Enabled FxCopAnalyzer for Wox.Plugin

* Fixed build errors - CA1824: Mark assemblies with NeutralResourcesLanguageAttribute
2020-10-26 18:18:21 -07:00
Divyansh Srivastava
d2435262ec
handle COM error to fetch description (#7563) 2020-10-26 16:37:27 -07:00
Luthfi Mawarid
cbb4307f6d
[fxcop] Microsoft.Plugin.Uri.UnitTests (#7562)
* Enable FxCop for Microsoft.Plugin.Uri.UnitTests

* Fix indentation
2020-10-26 16:15:05 -07:00
csigs
46f5bfbe22 LEGO: check in for master to temporary branch. 2020-10-26 23:05:24 +00:00
Avneet Kaur
ca1e5d111a
[fxcop] Fixes for Wox.Plugin (1of3) (#7457)
* Added CultureInfo (CA1307: Specify StringComparison for clarity / CA1304: Specify CultureInfo)

* Check arguments and throw ArgumentNullException (CA1062: Validate arguments of public methods)

* Changed url parameter from string to System.Uri and added null checks (CA1054: URI parameters should not be strings)

* Rethrow exception without specifying the exception explicitly (CA2200: Rethrow to preserve stack details)

* Changed from Collection property to methods for PluginMetadata::ActionKeywords (CA2227: Collection properties should be read only)

* Changed from Collection property to methods for Result::GetTitleHighlightData (CA2227: Collection properties should be read only)

* Made Collection property read-only and added parameter in constructor for Result::SubTitleHighlightData (CA2227: Collection properties should be read only)

* Made Collection property read only and added parameter in constructor for ResultUpdatedEventArgs::Results (CA2227: Collection properties should be read only)

* CA1507: Use nameof in place of string

* Removed initialization for ThemeManager::_disposed (CA1805: Do not initialize unnecessarily)

* Changed Query::Terms array property to ReadOnlyCollection and added private set (CA1819: Properties should not return arrays)

* CA1060: Move P/Invokes to NativeMethods class

* CA1806: Do not ignore method results

* CA2101: Specify marshaling for P/Invoke string arguments

* Removed unnecessary empty interface IFeatures (CA1040: Avoid empty interfaces)

- Removed IFeatures interface and references
- Renamed IFeatures.cs to IContextMenu.cs according to guidelines

* Added comments for CultureInfo (CA1307: Specify StringComparison for clarity / CA1304: Specify CultureInfo)

* Added localization for Wox.Plugin and localized strings in FilesFolders.cs
2020-10-26 15:14:33 -07:00
Alekhya Reddy
c76c4f026e Ensure the keyword version is read out before reading out the version number 2020-10-26 14:45:04 -07:00
Clint Rutkas
3906896947
Merge pull request #7537 from microsoft/user/martinchrzan/ColorPickerShowColorWhenFormatChanged
Update string color represention when color format changed, but mouse…
2020-10-26 11:29:01 -07:00
Clint Rutkas
825e7a7533
[Settings] FZ MDL2 icon fix (#7517)
* Fixed fancy zones MDL2 icon

* Updated FZ icon
2020-10-26 11:14:02 -07:00
Alekhya
e411e6dc75
Catch Exceptions when settings.json is corrupted (#7553)
* added a json exception catch statement as a fail safe to create a fresh configuration file when settings is corrupted

* change formatting

* add issue link

* add extra info in the comment
2020-10-26 11:13:53 -07:00
Luthfi Mawarid
39ebd82e20
[fxcop] Settings UI runner (#7485)
* Enable FxCop for Microsoft.PowerToys.Settings.UI.Runner

* Log exceptions in WindowsXamlHost_ChildChanged

* Add Debugger.Break in debug mode

* Move Debugger.Break into Logger class
2020-10-26 11:09:18 -07:00
Arjun Balgovind
ec22bc40bc
Switch focus to last Image Size ListViewItem on adding new size (#7505) 2020-10-26 11:06:35 -07:00
yuyoyuppe
129342edff FZ: format FancyZones.cpp 2020-10-26 20:21:04 +03:00
yuyoyuppe
8ca0c35242 FZ: fix nullptr crash 2020-10-26 20:21:04 +03:00
csigs
48292fb189 LEGO: check in for master to temporary branch. 2020-10-26 11:05:34 +00:00
stefansjfw
e6a5b589ff
[FancyZones] Align zone numbers between Editor and FancyZonesLib (#7387)
* Align zone numbers between Editor and FancyZonesLib
Use zoneId on win+arrow

* Update tests

* Fix crash

* ZoneId starts from 0

* Define ZonesMap type

IFACEMETHOD_ macro is having trouble processing
std::map template when expanding, so return type needs
to be predefined

* Address PR comment

* Address more PR comments

* Handle .at
2020-10-26 09:07:11 +01:00
Enrico Giordani
8ea09e0c95
[Keyboard Manager] new icon (#7492) 2020-10-25 22:54:48 +01:00
Martin Chrzan
854828e4ca Update string color represention when color format changed, but mouse is hovering on top of the same color 2020-10-25 18:00:59 +01:00
Niels Laute
bea1cf92d8 Updated FZ icon 2020-10-25 15:21:14 +01:00
Niels Laute
fa37d53cd9 Added Windows color settings link 2020-10-25 14:47:47 +01:00
Niels Laute
344013d860 Updated labels 2020-10-25 14:37:43 +01:00
Niels Laute
61a2e5297f Fix resource issue 2020-10-24 16:35:10 +02:00
Niels Laute
93627d2bbe Merge branch 'master' into users/niels9001/settings-accesbilitynarratorsupportforshortcutcontrol 2020-10-24 15:45:36 +02:00
csigs
2ef451aa4a
LEGO: check in for master to temporary branch. (#7508) 2020-10-24 06:36:20 -07:00
Niels Laute
36b628df48 Fixed fancy zones MDL2 icon 2020-10-24 15:06:12 +02:00
Davide Giacometti
146e7866a6
[PT Run] Option for override theme (#7355)
* option for override PT Run theme

* fix startup theme detection and moved strings in resources

* xaml fixed

* fix title spacing

* launcher theme fix

moved theme enum
removed settings direct access

* missing files

* theme manager dispose removed

Co-authored-by: Clint Rutkas <clint@rutkas.com>
2020-10-23 15:05:07 -07:00
Alekhya
6424667396
Define Heading levels in Settings App (#7496)
* Add shell page headings

* add headings for all the PTsettings

* add heading level 1 for the heading of each page

* Add heading level to the style instead of redifining it multiple times

* revert adding level2 for each control

* add heading level for run as admin because it does not follow the group style and rather the default style
2020-10-23 13:35:57 -07:00
Avneet Kaur
beecdc8d79
[fxcop] Fixes for Wox.Plugin (2of3) - Moved logger interface to Wox.Plugin (#7464)
* Moved Logger/Log.cs from Wox.Infrastructure to Wox.Plugin

- Installed Logger dependency in Wox.Plugin: NLog.Extensions.Logging
- Moved file Log.cs from Wox.Infrastructure/Logger/ to Wox.Plugin/Logger
- Moved file Constant.cs from Wox.Infrastructure to Wox.Plugin: This file was moved since Log.cs depends on this class
    - Copied Wox.Infrastructure.Helper.NonNull to Wox.Plugin.Constant since Constant.cs depends on this method
- Replaced all "using Wox.Infrastructure.Logger" to "using Wox.Plugin.Logger" in all files as needed
- Replaced Wox.Infrastructure.Constant to Wox.Plugin.Constant in all files as needed

* Removed Nlog.Extensions.Logging from Wox.Infrastructure

* Added logging and suppressed general exceptions (CA1031: Do not catch general exception types)

* Resolved fxcop errors introduced by newly added Log.cs

- CA1307: Specify StringComparison for clarity
- CA2000: Dispose objects before losing scope
- CA1062: Validate arguments of public methods

* Replaced Wox.Infrastructure.Logger with Wox.Plugin.Logger
2020-10-23 13:06:22 -07:00
Arjun Balgovind
6ae8d6749a
Removed AnyCPU config (#7502)
Forcing this to merge a s build has completed successfully, and pr is approved.
2020-10-23 11:56:57 -07:00
Divyansh Srivastava
ba07b52cc2
Remove unused pinyin code (#7455)
* Remove pinyin

* Remove pinyin mappings and files

* Remove pinyin files from MSI
2020-10-23 10:34:24 -07:00
Niels Laute
87128ceee6
Merge branch 'master' into users/niels9001/settings-accesbilitynarratorsupportforshortcutcontrol 2020-10-23 16:16:09 +02:00
Niels Laute
773c57e609 File format limitations are now announced by Narrator 2020-10-23 16:10:16 +02:00
Niels Laute
7c42162618 Updated string 2020-10-23 15:57:34 +02:00
Niels Laute
466a0015e9 Fixed tooltip call out with narrator 2020-10-23 15:44:31 +02:00
Arjun Balgovind
859e9f8b04
Added ColorPicker unit tests to CI and moved the unit test project (#7484)
* Added ColorPicker unit tests to CI and moved the unit test project

* Updated output path
2020-10-22 19:26:48 -07:00
Arjun Balgovind
3f5810bfdb
[Fix Build farm]Fix ImageResizer Loc and change C# language version in ColorPicker to 8.0 (#7483)
* Removed duplicate resx addition

* Changed version to 8.0
2020-10-22 17:28:25 -07:00
Clint Rutkas
5b86885cd1
Settings accessibility issues with clipping on large text (#7459)
* Fix issues found in 7068

* fixed a few more
2020-10-22 14:37:10 -07:00
Luthfi Mawarid
f92bd6ffd3
[fxcop] Settings UI library (part 4) - project/namespace renames (#7403)
* Rename Interface to Interfaces in namespaces

* Rename Lib to Library in namespaces

* Rename project and directory and enable fxcop

* Add CA2213 suppression

* Minor fixes
2020-10-22 09:45:48 -07:00
Davide Giacometti
aa0947061a
[Image Resizer] Upgraded to .NET Core 3.1 (#7317)
* project converted to sdk style

* image resizer core31

* image resizer test core31

* project and setup fixes
2020-10-22 09:26:46 -07:00
Clint Rutkas
e2c94b592f
Upgrade mahapps to 2.3 (#7466) 2020-10-22 08:30:18 -07:00
Mehmet Murat Akburak
31799cd019
Widen text labels (#7475) 2020-10-22 18:25:13 +03:00
yuyoyuppe
ec18e31ff1 settings: use actionable toast notifications for file explorer modules warning 2020-10-22 18:24:54 +03:00
yuyoyuppe
5e772340bc updating: remove previous progress toasts
toast notifications:
- add method for removing existing toasts
- add method for updating existing toast contents/title
- refactoring
2020-10-22 16:36:20 +03:00
Mehmet Murat Akburak
3d0254bdeb
[PowerRename] Fix UI for Localized Strings (#7467)
* Put the options in two columns. Rearrange options.

* Expand "Search for" label
2020-10-22 13:09:59 +03:00
Avneet Kaur
cfe9e2328f
FxCopAnalyzer fixes for Wox.Test (#7312)
* Added InvarientCulture info (CA1305: Specify IFormatProvider)

* Removed underscore from method names (CA1707: Identifiers should not contain underscores)

* Marked members as static (CA1822: Mark members as static)

* Removed initialization for DummyTestClass::IsFunctionCalled (CA1805: Do not initialize unnecessarily)

* Replaced Count with Any (CA1827: Do not use Count/LongCount when Any can be used)

* Changed WoxTest::DummyTestClass to private (CA1034: Nested types should not be visible)

* Suppressed warnings for uninstantiated internal classes used as TestFixtures (CA1812: Avoid uninstantiated internal classes)

* Enabled FxCopAnalyzer for Wox.Test

* Added suppression message for CA1812 in GlobalSuppressions.cs and removed inline supression messages (CA1812: Avoid uninstantiated internal classes)

* Changed InvariantCulture to Ordinal where appropriate

* Addressing comments: Updated justification for CA1812 in GlobalSuppressions.cs (Avoid uninstantiated internal classes)
2020-10-21 20:13:12 -07:00
Alekhya
dd2627dbbc
Fix exceptions and incorrect results within the calculator plugin (#7438)
* remove functions which mages cannot interpret and add in functions which mages can

* set validResult when the result is explicitly created to differentiate it form an empty CalculateResult

* Add condition to check that the input is not ending with a binary operation

* add tests for all the cases

* use valid result while calculating hash as well

* add test for e is valid within regex

* removed i from regex

* remove valid result to use decimal? instead

* remove duplicate rand and exp
2020-10-21 16:19:37 -07:00
Luthfi Mawarid
86d77103e9
[fxcop] Settings UI library (part 3) - exception handling (#7385)
* Log general exceptions caught in Settings

* Rethrow argument-related exceptions in debug mode

* Log ColorPicker settings errors into Settings Logs
2020-10-21 12:32:53 -07:00
Roy
29ed39c7ae
Enable starting apps with command line arguments when run as admin is selected (#6923)
* Enable Run as Admin Arguments

* Use a seperate function for both methods which were generating ProcessStartInfo fixes missing LnkResolvedPath missing in contextmenu (E.g. Shortcuts / PWA's).

* Update tests

* Move ProgramArguments to Result class

Co-authored-by: Roy <royvou@hotmailcom>
2020-10-21 11:49:55 -07:00
vldmr11080
8d9e85f4f5
[FancyZones] Add AutomationProperties.Name to focusable elements (#7372)
* Add AutomationProperties.Name to focusable elements

* Add AutomationProperties.Name to focusable elements

* Use AutomationProperties.LabeledBy with buttons / text boxes

* Address PR comments
2020-10-21 20:11:32 +02:00
Tobias Sekan
73df7b5deb
[ColorPicker] CMYK, HSV and HSL color format (#6975)
* Add HSL and HSV color formats + cleanup + docu

* Fix build problem (lang version)

* Add CYMK color + replace float with double values

* ups - fix cmyk text format

* fix wrong settings text + doc typo fix

* Address feedback

* Address feedback + fix to small window size

* adress feedback + more cleanup

* typo fix

* Avoid possible division by zero + unit test

* Address feedback - move all represenation to own helper class + UnitTest

* Address feedback -> switch to mstest framework
2020-10-21 11:09:30 -07:00
Arjun Balgovind
cd8c9c5375
Tweaked KBM comment, removed redundant assignment, and avoid sending key up for one case when not necessary (#7315)
* Changed one case to release key only if it is pressed, tweaked a comment

* Remove redundant assignment
2020-10-21 10:24:43 -07:00
yuyoyuppe
f506980e4d previewpane: use RAII for FileExplorerPreviewSettings classes to avoid memory leaks 2020-10-21 15:10:56 +03:00
yuyoyuppe
e05146acf9 update Microsoft.Windows.ImplementationLibrary nuget package 2020-10-21 12:31:22 +03:00
Mykhailo Pylyp
eaec26a012
Fix dropdown popup narrator bug (#7422) 2020-10-21 11:14:30 +03:00
csigs
3801ad3030
LEGO: check in for master to temporary branch. (#7436) 2020-10-20 21:17:06 -07:00
Arjun Balgovind
4da4673e24
[KBM] Ignore IME keys while checking keyboard state for Shortcut Remaps (#7386)
* Ignore IME keys while checking keyboard state for Shortcut Remaps

* Add bool check

* Update Shortcut.cpp
2020-10-20 16:14:48 -07:00
Clint Rutkas
a1782f31b2
Update Version.props 2020-10-20 15:58:26 -07:00
Clint Rutkas
f4d0ef19fb
Merge branch 'master' into dev/crutkas/buildFarmVersioningTake3 2020-10-20 15:58:08 -07:00
Divyansh Srivastava
466ed10f3d
Fix autocomplete text issue on query change (#7392)
* Fix autocomplete text issue on query change

* Update from invariant to ordinal case for exact byte to byte matching

* Add tests for checking when autocomplete should be empty
2020-10-20 14:53:32 -07:00
Arjun Balgovind
9a9424a975
Add null check for WindowsXamlHost_ChildChanged handler (#7426) 2020-10-20 12:50:04 -07:00
csigs
334e612bce
LEGO: check in for master to temporary branch. (#7411) 2020-10-20 11:22:47 -07:00
Alekhya
14e74376d9
Use task delay instead of thread sleep (#7401)
* Use task delay instead of thread.sleep to free up the blocked thread

* fix formatting
2020-10-20 11:13:53 -07:00
Avneet Kaur
58cf165eb4
Enabled FxCopAnalyzers for Wox.Core.csproj (#7212) 2020-10-20 10:36:18 -07:00
yuyoyuppe
7c07bc2717 interop: fix possible crash in keyboardhook
also treat warnings as errors
2020-10-20 17:52:21 +03:00
yuyoyuppe
83872046fa autoupdating: ignore local builds 2020-10-20 17:46:50 +03:00
Avneet Kaur
701ccfdbcc
FxCopAnalyzer fix for Wox.Core (PR#2of3) - Removing unused JsonRPC files (#7211)
* Removed unused JsonRPC related files and references

- Files Removed: ExecutablePlugin.cs, JsonRPCClientRequestModel.cs, JsonRPCErrorModel.cs, JsonRPCModelBase.cs, JsonRPCPlugin.cs, JsonRPCQueryResponseModel.cs, JsonRPCRequestModel.cs, JsonRPCResponseModel.cs, JsonRPCResult.cs, JsonRPCServerRequestModel.cs
- Modified PluginsLoader.cs:
	- Removed method ExecutablePlugins
	- In method Plugins(): Removed call to ExecutablePlugins()

* Suppressed warning for catching general exception type

* Addressing comments: Replaced in source suppression with attribute and logged exception information
2020-10-19 19:48:51 -07:00
Divyansh Srivastava
280d1907d8
Non localized module name (#7170)
* Added get_key to powertoysmodule interface

* Replace get_name with get_key

* Implement get_key function in modules

* Make key global constant in each module

* Update settings v1 to use key to load and save files

* Fixed fancyzones and preview pane unit tests

* Removed setings unit test as the case is not covered anymore

* Add constant files for modules and use it to reference module key

* Add constant string files to colorpicker, launcher and shortcut guide

* correct sunction signature in settings helper

* Fix powerpreview merge conflicts

* nit fix with include statement location

* add check for fields in from_json_string

* Updated preview pane tests with correct from_json_string signature

* Correct Image resizer naming

* Roll back changes for adding check for property and version

* Fix image resizer not working
2020-10-19 16:07:02 -07:00
Avneet Kaur
8b759094f7
FxCopAnalyzer fixes for Wox.Core (#7209)
* FxCop Fixes- added InvarientCulture info, suppressed warnings for general exception types

* Used IsNullOrEmpty to test for empty strings (CA1820: Test for empty strings using string length)

* Check if arguments are null and throw ArgumentNullException

* Removed unused function argument from PluginsLoader.cs

* Addressing comments- Using attributes to suppress errors for general exception types

* Addressing comments- Using attributes to suppress errors

* Addressed comments and changed InvariantCulture to CurrentCulture/Ordinal where appropriate

* Addressing comments - catching and logging specific exception in FontHelper.cs
2020-10-19 15:46:56 -07:00
yuyoyuppe
0aae535986 fix low-level kb hook disabling macro 2020-10-20 00:21:04 +03:00
Luthfi Mawarid
688f134051
[fxcop] Settings UI library (part 2) (#7257)
* Suppress warnings for read-only collection properties (see code comments)

* Call ConfigureAwait on tasks

* Add CultureInfo and StringComparison policy for certain string operations

* Add checks and exceptions for null arguments to public methods

* Rename RaisePropertyChanged to NotifyPropertyChanged

* Suppress CA1000 warning on SettingsRepository class

* Implement Disposable pattern in HotkeySettingsControlHook

* Modify null argument handling in KeyboardManagerViewModel::CombineShortcutLists
2020-10-19 13:32:05 -07:00
Andrey Nekrasov
03509e7f36
Logging improvements (#7377)
* bootstrapper: fix Windows SDK version

* devdocs: add spdlog usage readme
2020-10-19 10:54:39 -07:00
Gordon Watts
4660dd4970
Add action keywords for each plugin (#6129)
* Add action keywords for each plugin

- Added keywords for each plug-in
-  Change window walker search to use Query, not RawQuery (to get rid of action keyword)
- Make sure plug-ins that have action keywords as well as are in global list don't get added twice

All tests passed that passed before I started

Addressing issue #5823

* Fix bad formatting from the merge

* Do not add global plug-ins if we have an action keyword

Note side effect: you will not not be able to search for things that start with one of the plug-in keywords.

* Missed merge conflict repair!

* Revert "Do not add global plug-ins if we have an action keyword"

This reverts commit e3b0ecd708.

* Adjust keywords to suggested ones

* No need to ubild a query if we aren't going to use it

Didn't quite get the if statement right the first time I put it in.

* Do not add global plugins if we have an action keyword

This means, especially without a space, that global plugins do not become part of the search. Which really narrows down the search results, nicely.

* Update keywords as requested in the PR
2020-10-19 10:42:01 -07:00
csigs
12a84c01b1
LEGO: check in for master to temporary branch. (#7346) 2020-10-19 10:23:15 -07:00
csigs
06de5ffa07
LEGO: check in for master to temporary branch. (#7338) 2020-10-19 10:22:30 -07:00
Mykhailo Pylyp
7e0574cba2
Get rid of indexes in dropdowns (#7278) 2020-10-19 12:27:47 +03:00
Davide Giacometti
b80578b1b9
[PT Run] Open folder using shell instead of explorer.exe (#7292)
* pt run not using explorer.exe for opening path (#4622)

* updated explorer action name (#4622)
2020-10-16 16:30:11 -07:00
csigs
36dd29c056
LEGO: check in for master to temporary branch. (#7327) 2020-10-16 11:03:43 -07:00
csigs
6f5cdb4674
LEGO: check in for master to temporary branch. (#7319) 2020-10-16 08:59:49 -07:00
yuyoyuppe
c34c963121 bootstrapper: implement logging support
- add cxxopts and spdlog libraries
- implement cmd flag for severity
- add debug and error messages
2020-10-16 16:30:26 +03:00
stefansjfw
36bcbe9d95
[FancyZones] Minor refactoring of ZoneSet class (#7274)
* Minor refactoring of ZoneSet class

* Remove comment
2020-10-16 15:25:30 +02:00
Mykhailo Pylyp
4634c74f9e
Remove Drop Down from combo box name as it is redundant (#7307) 2020-10-16 14:09:57 +03:00
csigs
c576bb611d
LEGO: check in for master to temporary branch. (#7305)
Co-authored-by: Clint Rutkas <clint@rutkas.com>
2020-10-15 13:19:50 -07:00
Enrico Giordani
5f86956a41
[PowerRename] new icon (#7309) 2020-10-15 11:13:58 -07:00
csigs
fd7c7ffd57
LEGO: check in for master to temporary branch. (#7294) 2020-10-15 10:33:40 -07:00
Arjun Balgovind
438169e64f
[KBM] Fix shortcut remap scenarios that should/should not open start menu (#7171)
* Modify  shortcut to key code more similar to shortcut to shortcuts code. Manually tested cases

* Fixed existing tests and fixed scenario with other keys pressed and action key released

* Fixed dummy key usage

* Updated comments and removed dummy key usage in key to shortcut remaps

* Added tests for disable and shortcut to key. Pending tests for dummy key

* Added test cases for each usage of dummy key event

* Remove redundant check
2020-10-15 08:53:43 -07:00
Ivan Stošić
598729f84c
Remove m_drawHints, fix duplicate zone drawing (#7300) 2020-10-15 17:08:55 +02:00
Niels Laute
001c3304a2
Merge pull request #7259 from microsoft/user/niels9001/settings-placeholdertext
[Settings] Added placeholder labels
2020-10-14 20:31:16 +02:00
csigs
eeeae65493
LEGO: check in for master to temporary branch. (#7276) 2020-10-14 10:42:43 -07:00
csigs
184b6c5bd0
LEGO: check in for master to temporary branch. (#7265) 2020-10-14 10:42:15 -07:00
Arjun Balgovind
70bc967219
Updated double quotes logic (#7268) 2020-10-14 09:03:45 -07:00
vldmr11080
944e605f06
Allow negative spacing between zones up to -10 (#7284) 2020-10-14 17:42:47 +02:00
stefansjfw
d1372af581
[FancyZones] Refactor Zone class (#7022)
* Pass zoneId on zone creaton and make it const
Refactor IZone and Zone - make methods const
and remove SetId

* Update tests

* Fix Grid layout zone order
2020-10-14 09:00:50 +02:00
Niels Laute
3f4336697e Improvements 2020-10-13 23:30:29 +02:00
Niels Laute
ac94bbe575 Added improved narrator support for custom shortcut control 2020-10-13 22:24:15 +02:00
Niels Laute
539b834da9 Added placeholder labels 2020-10-13 21:30:57 +02:00
csigs
8ade8fb2c5
LEGO: check in for master to temporary branch. (#7253) 2020-10-13 10:06:05 -07:00
Roy
844a68dae0
Improve DeduplicatePrograms by using a set instead of distinct (#7223)
Co-authored-by: Roy <royvou@hotmailcom>
2020-10-13 09:31:07 -07:00
vldmr11080
954705e3a0
[FancyZones] Screen enumeration improvement (#6908)
* Improvements in enumeration of available screens (work areas)

* Minor code style improvement

* Address PR comments

* Store map of display device name to device index

* Address PR comments

* Update comment

* Break when suitable device is found
2020-10-13 17:22:25 +02:00
Arjun Balgovind
dde19380e9
[Localization] Add localized resource dlls to the MSI installer (#6986)
* Added PowerLauncher resource files

* Fixed typo in language

* Updated localized .NET framework projects to include all resx files

* Fixed typo in FZEditor.csproj

* Added FZ Editor (.NET framework) resource dlls

* Updated pipeline

* Tweaked artifact statement to get all resource dlls in pipeline

* Fix SvgPreviewHandler resx inclusion in csproj

* Added condition to allow local MSI builds to run without resources

* Generalized directory code

* Added all resources that are to be added from C# projects, Settings UWP pending

* Added markdown prev handler as keypath

* Added loc script for Settings to move resw files to UWP file format

* Separate markdown and svg resource components to allow guid auto-generation

* Removed old image resizer resources

* Fixed formatting

* Changed tabs to space
2020-10-13 08:20:33 -07:00
Ivan Stošić
bb8cc0a305
Restart the launcher if it had crashed when invoked (#7127) 2020-10-13 10:26:04 +02:00
csigs
45124c2245
LEGO: check in for master to temporary branch. (#7246)
Co-authored-by: Clint Rutkas <clint@rutkas.com>
2020-10-12 21:44:15 -07:00
csigs
6e8cc67824
LEGO: check in for master to temporary branch. (#7236) 2020-10-12 19:22:52 -07:00
csigs
c6a82ef199
LEGO: check in for master to temporary branch. (#7217) 2020-10-12 16:59:32 -07:00
Roy
1f1cff3389
Fixed wrong name logged in Program Plugin (#7244)
Co-authored-by: Roy <royvou@hotmailcom>
2020-10-12 15:33:09 -07:00
csigs
d9d328173b
LEGO: Pull request from lego/hb_2939_20201009230714095 to master (#7210)
* LEGO: check in for master to temporary branch.

* Update pipeline.user.windows.yml

Co-authored-by: Clint Rutkas <clint@rutkas.com>
2020-10-12 15:31:47 -07:00
Ivan Stošić
6161531376
[FancyZones] Responsive drawing (#7125)
* Made drawing zones not clog message processing

* Fixed synchronization bugs

* call BufferedPaintInit

* Some refactoring, the animation is back

* Rename a function

* Align parameters
2020-10-12 11:05:22 +02:00
Seraphima Zykova
3807e98f23
[PT runner] Misplaced 'return' statement fix (#7202) 2020-10-12 11:57:50 +03:00
Luthfi Mawarid
889f20c4a7
[fxcop] Settings UI library (part 1) (#7187)
* Mark methods static and replace Count() with Length

* Use IsNullOrEmpty for null string checks

* Remove redundant initializations to default values

* Use nameof(property name) in place of string literals

* Add NativeMethods class

* Rename property getters in KeysDataModel & AppSpecificKeysDataModel

* Remove underscores from method names

* Mark Helper class static

* Address comments & typo fixes

* Add EncoderGuid property and fix failing build

* Update binding in GeneralPages.xaml
2020-10-09 17:58:52 -07:00
Arjun Balgovind
8643bfc977
Change declaration order of delay thread member in KeyDelay (#7206) 2020-10-09 16:13:48 -07:00
Arjun Balgovind
7fd5e18ef4
[File Explorer] Fix enable/disable for File Explorer PowerToy (#6883)
* Commented out enable/disable for File Explorer

* Revert UI changes

* Disable the toggles if PT is not running elevated

* Fixed compilation errors in tests

* Cleaned up preview pane code to separate thumbnail and preview panes as separate classes

* Fixed broken settings format and added elevation check and registry updated required logic. Preview Handler tested manually working, Thumbnail Enable/Disable needs to be fixed

* Updated Thumbnail enable/disable logic and added warning messages

* Update tests for File Explorer

* Fixed RegGetValue failing in Release config

* Renamed new classes

* Split wrappers for disable to work

* Modified enabled flag check to also check if user is on new settings. Fixed casing issue in powerpreview.h that caused a dialog prompt on first launch after install

* Update fontweight and margin

* Fixed release build not working

* Move UseNewSettings usage to powerpreview.cpp to avoid tests breaking. For new settings the enable check is done in constructor and for old settings it is done in enable

* Update src/core/Microsoft.PowerToys.Settings.UI/Strings/en-us/Resources.resw

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>

* Update src/core/Microsoft.PowerToys.Settings.UI/Strings/en-us/Resources.resw

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>

* Update src/core/Microsoft.PowerToys.Settings.UI/Strings/en-us/Resources.resw

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>

* Moved dup code to method

* Use correct versions of general settings for backwards compat test

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>
2020-10-09 14:45:30 -07:00
csigs
d753179d1e
LEGO: check in for master to temporary branch. (#7186)
Co-authored-by: Arjun Balgovind <32061677+arjunbalgovind@users.noreply.github.com>
2020-10-09 14:32:31 -07:00
csigs
bd3c877ca3
LEGO: check in for master to temporary branch. (#7195) 2020-10-09 09:38:36 -07:00
Niels Laute
274c009f20
[PT Run] Updated borderbrush to improve accessibility for dark mode (#7141)
* Updated borderbrush

* Update src/modules/launcher/PowerLauncher/LauncherControl.xaml

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>

* Fixed bug

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>
2020-10-08 20:14:00 -07:00
Arjun Balgovind
210426a020
Fixed lcl file bad merge (#7189) 2020-10-08 19:38:21 -07:00
Arjun Balgovind
c393db0b65
[KBM] Fix remaps to arrow keys/Home/Ins, etc not working with Windows Terminal (#7143)
* Added MapVirtualKey call to set scancode before calling SendInput

* Updated comment

* Update comment with link

* Added test for dummy key scan code
2020-10-08 17:52:19 -07:00
Nkateko
1390b57d3e
[Settings] Adding Tests to Verify Backward Compatibility (#6161)
* compare config files

* create settings files

* updated path check

* reverted color picker changes

* added test files

* removed settings uralted files

* Modifying directory structure and adding properties for backcompat test.

* Updating Unit test to use mock repositories.
1) BackCompatTestProperties exposes mock repository implementation because SettingsRepository is a singleton, and settings utils isn't typed.
2) BackCompatTestProperties, encapsulates logic to verify that the correct file was read from.
3) Validating each file is read twice.  Once by the original file, and once via the view model.

* Adding 18.2 settings files.

* Fix compiler errors from latest merge

* Adding v0.19.2 test files.

* Adding in 0.20.1 settings.  Removing 0.20.2 (as this was a dev build number)

* Adding settings tests for 22.1

* General Settings should update version when they don't match

* Adding v0.22.0 files

* Removing not settings related files from TestData for PT Run 21.1

* Referencing module name as *Settings.ModuleName in tests.  Except for ImageResizer

* Using ImageResizerSettings to use Settings for the module name.

* Setting AllPlugins to empty list in case PluginManager.Save/Load/ReloadData is called before plugins are loaded

* Fixing fxcop errors

* using named parameters as per review feedback

Co-authored-by: ryanbodrug-microsoft <56318517+ryanbodrug-microsoft@users.noreply.github.com>
2020-10-08 16:34:19 -07:00
ryanbodrug-microsoft
4451403c1e
Setting AllPlugins to empty list in case PluginManager.Save/Load/ReloadData is called before plugins are loaded (#7173) 2020-10-08 16:32:31 -07:00
Tony Mitchell
38e03e6bb0
Detect potential errors copying metadata and avoid them (#2447) (#6997) 2020-10-08 16:16:32 -07:00
Arjun Balgovind
42ebc42c98
Changed dummy key event to send key down and key up to improve compatibility with applications (#7166) 2020-10-08 11:28:37 -07:00
Arjun Balgovind
e1d22c74b0
[KBM] Refactor KBM's thread safety logic to avoid mutex re-entrancy bugs and improve performance (#6803)
* Unlock mutex before ResetModifierForLowerLevelKeyHandlers method to avoid crash if two instances of KBM are running

* Added alias for Shortcut DWORD variant to clean up code

* Removed mutex usage in single key remap method and added GetSingleKeyRemap

* Added more alias

* Moved to boolean disable remapping

* Added missing ! in condition

* Remove lock statement from bad auto-merge
2020-10-08 11:28:24 -07:00
Clint Rutkas
9928579364
Adjusting to force all instances to use rounded vs result due to Mage's quirks (#7164) 2020-10-08 08:57:17 -07:00
Alekhya
cfe2bbd75e
Fix Tab Trap in SettingsHotkey Custom Control (#7136)
* basic logic working

* Added a literal for ignore flag which cna be shared by all the files

* Added a condition that the other modifier keys should not be pressed

* Added comments to describe each scenario

* sometimes when multiple modified keys were involved the shift+tab key press was also being invoked, so added an additional check in the IsValid function

* use variable for vk_tab

* remove new line before initializing dwextraInfo

* move flag check if the filterKeyboardevent function

* use windows.system.virtualkey.shift instead of defining a constant for the shift key code

* removed latest settings to use internal settings instead. Removed the validity check while still within the hotkey other than if it's tab or shift+tab

* add a function to send input to the system instead of duplicating the send input code

* remove VKSHIFT declaration

* display all shortcuts/keys except tab and shift+tab

* remove header that is no longer needed
2020-10-08 08:45:09 -07:00
csigs
8a81bea413
LEGO: check in for master to temporary branch. (#7168) 2020-10-08 07:55:56 -07:00
csigs
9216aa465f
LEGO: check in for master to temporary branch. (#7181) 2020-10-08 07:54:53 -07:00
Enrico Giordani
038087e076
[FancyZones] Clone parent data only for new VD (#7116)
* [FancyZones] Clone parent data only for new VD
2020-10-08 16:02:51 +02:00
csigs
de4436ccc0
LEGO: check in for master to temporary branch. (#7153) 2020-10-07 13:30:34 -07:00
csigs
5e30ad176a
LEGO: check in for master to temporary branch. (#7144) 2020-10-07 13:30:12 -07:00
P-Storm
d011843113
Assert was switched in these instances, so I changed it to the "expected, actual" (#7142)
Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-10-07 13:12:59 -07:00
Alekhya
0c0aec0f2a
catch security exception and access denied exception while trying to read a file (#7140) 2020-10-07 12:56:57 -07:00
Divyansh Srivastava
2bd6c5c664
Fix Docker desktop not found in program plugin issue (#6882)
* Fix docker lnk not found issue

* Add common desktop folder location to desktop program

* Add CommonDesktopDirectory to file watchers
2020-10-07 12:27:56 -07:00
Arjun Balgovind
eae0937db0
Add null check in SelectPrevTabItem (#7139) 2020-10-07 12:22:54 -07:00
P-Storm
163a699bff
EnumerateFileSystemInfos uses EnumerationOptions (#6933)
* Changed EnumerateFileSystemInfos to EnumerationOptions we don't have to catch the exceptions ourself.

* Change Matchtype to mimic old search method.

Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-10-07 09:25:29 -07:00
P-Storm
8b66932036
Matching ExactName for known Win32 Programs (#6924)
* Matching explorer.exe also for explorer
Added unit test
Optimized multiple iterations for IProgram

* Fixed linter

Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-10-07 09:23:47 -07:00
Luthfi Mawarid
a2fce22973
[fxcop] Settings UI unit tests (#6987)
* Add FxCop to project

* Remove underscores from method names

* Add message to obsolete test method

* Mark method static

* Method renames and remove unused ToRGBHex method

* Method renames and replace Count() with the List.Count property

* Method renames, rename unused OnSend argument, validate argument for AssertHotkeySettings
2020-10-06 15:00:25 -07:00
P-Storm
206397dc86
Fixed the error that Files were named Folder (#6935)
* Fixed the error that Files were named Folder

* Add and use resources in Results.

* Last item without resources in Plugin.Folder

* Changed to CurrentCulture, added N0 to Folder truncate warning.

Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-10-06 09:08:41 -07:00
Yuhanun Citgez
ac3910580a
Modernized unique pointer construction (#6982) 2020-10-06 18:17:20 +03:00
lai52066
bee1af427b
Fix translate (#7005)
ORG <Val><![CDATA[輕]]></Val>
FIX <Val><![CDATA[淺色]]></Val>
2020-10-05 13:04:54 -07:00
Divyansh Srivastava
ea0de4f831
[Run] Fix for IndexOutOfBounds exception (#6981)
* Fix index out of bounds exception

* Race condition in query telemetry
2020-10-05 09:50:41 -07:00
Divyansh Srivastava
5d095efe90
Add exception handling in win32 program (#6958)
* Add exception handling to prevent program from failing due to error in one program

* Error handling for program path function

* Fix incorrect log value in ProgramLogger
2020-10-05 09:50:07 -07:00
vldmr11080
71765238b1
[FancyZones] Localize strings in FancyZones editor (#6943)
* Localize strings in FancyZones editor

* Move localized strings into resx file
2020-10-05 12:06:35 +02:00
Divyansh Srivastava
4feb0f209f
Fix autocomplete due to error in returned autocomplete text (#6988) 2020-10-02 21:30:14 -07:00
Arjun Balgovind
7c607ad540
Add AppxBundlePlatform to remove warning (#6960) 2020-10-02 13:42:47 -07:00
Mykhailo Pylyp
3f25d7ccc8
Keyboard disable (#6874)
Added disable key/shortcut functionality
2020-10-02 15:36:36 +03:00
Arjun Balgovind
b2e72e1ca4
[KBM] Moved unregistering of key delays to always run on the dispatcher thread to avoid mutex re-entrancy (#6959)
* Moved unregistering of key delays to always run on the dispatcher thread

* Updated comments
2020-10-01 18:19:11 -07:00
Divyansh Srivastava
55fd8749c8
Shift to ControlzEx HC code (#6880)
* Use high contrast detection from controlzex

* Allow multiple theme changes
2020-10-01 16:08:06 -07:00
P-Storm
fd32a6f7d6
Fix throwing when there is no results (#6934)
Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-10-01 13:47:58 -07:00
Arjun Balgovind
b981467f1e
[KBM] Avoid checking reserved/unassigned/oem-specific/undefined key codes during shortcut remaps (#6952)
* Updated list of key codes to be ignored

* Added comments
2020-10-01 12:43:54 -07:00
Clint Rutkas
c219fe0d1d
[fxcop] image resizer ui (#6841)
* adjustments

* Settings fixed

* Getting resizing tests operational again

* fixed default vs loading from settings

* one small tewak
2020-10-01 11:33:23 -07:00
stefansjfw
85f56f4ed8
[FancyZones] Fix stuck chrome tab when merging into existing window (#6931)
* Fix stuck Chrome tab when merging with existing window

* Rename struct fields
2020-10-01 15:38:24 +02:00
P-Storm
5c84de5400
Made Plugin Folder Unit tests & Expanding enviroment search (#6600)
* Made Plugin Folder Unit tests. Fixes '>' not recursive searching (with max). Added that paths with an UnauthorizedAccessException are ignored. Added expanding enviroment search.

* Fixed some merging errors

* Added feedback from review

* Made the change that  ryanbodrug-microsoft suggested

* Stupid merge request... fixed

Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-09-30 20:37:46 -07:00
csigs
67072b99d4
LEGO: check in for master to temporary branch. (#6907) 2020-09-30 10:26:54 -07:00
stefansjfw
39c61b9abd
[FancyZones] Remove WindowMoveHander pImpl pattern (#6894)
* Remove WindowMoveHandlare pImpl pattern

Introduces runtime overhead and makes debugging unecessary more painful

* End file new line
2020-09-30 09:19:20 +02:00
Divyansh Srivastava
24ba7f08cf
Add debugging section in preview pane (#6717)
* Added info on directly registering dll

* Update README.md

* Update README.md

* Update to regasm x64

* Add information related to assembly signing in readme preview pane handler

* Bold warning for taking registry route for installation
2020-09-29 14:36:28 -07:00
Clint Rutkas
fb8e80c09c
FxCop for Preview handler (#6833) 2020-09-29 10:43:18 -07:00
Seraphima Zykova
240f67f15c
Fixed crash with big 'Space around zones' values (#6815) 2020-09-29 13:12:21 +03:00
Enrico Giordani
8d18626659
Now working on 0.23.1 (#6881) 2020-09-29 12:05:36 +02:00
Alekhya
a5b22cffa2
Changed default theme in settings to be consistent with that of shortcut guide (#6832)
* changed default theme to be consistent with that of shortcut guide

* change the test to reflect that the initial settings theme or shortcut guide is 'system' and not 'light'.
2020-09-28 12:44:18 -07:00
Arjun Balgovind
de870c843e
Fix settings UpgradeConfiguration code path (#6839) 2020-09-25 13:59:14 -07:00
Arjun Balgovind
9c32e32097
Updated winUI version (#6840) 2020-09-25 13:52:43 -07:00
Alekhya
f61db8ed3f
Add delay to File System watchers to prevent Calibre installation issue (#6821)
* add a separate task to dequeue and create an app on installation

* Added tests to validate the behavior of the event handler

* release unmanaged memory
2020-09-25 10:36:38 -07:00
Arjun Balgovind
9e1711cbb9
[Settings] Added recursive delete for IOProvider DeleteDirectory to prevent crash on non-empty directory (#6818)
* Added recursive delete flag

* Changed to named parameter
2020-09-24 11:36:26 -07:00
Alekhya
c941b5333c
Fix settings changes that were made in PR #6620 (#6817)
* validated that restart elevated and check for updates work.Removed isettingsUtils and reused settings repository

* reverted the name to ImageResizer instead of using ImageResizerSettings.Modulename to make it backward compatible
2020-09-24 10:50:49 -07:00
csigs
2f0937951a
LEGO: check in for master to temporary branch. (#6802) 2020-09-24 08:01:13 -07:00
Ivan Stošić
a676537e26
[FancyZones editor] Rudimentary crash handler (#6783)
* Handle crashes in the FZ editor

* Removed reference to .NET frameworks, added a message box

* log => txt

* Update text shown
2020-09-24 12:29:53 +02:00
Clint Rutkas
b071220b6c
Improve logging for PT Run (#6800)
* init code pass

* adjusting tabbing for readabilty

* few small adjustments
2020-09-23 16:32:06 -07:00
Alekhya
dafc1e0c7d
Fixed scaling Accessibility issues in Settings (#6774)
* fixed scaling issues in settings

* reduced the size to 375 from 380

* Set scrollviewer visibility to auto so that it is visible only when needed
2020-09-23 13:20:58 -07:00
Alekhya
5a07579b73
Fix for settings crash on toggling enable button for any PowerToy (#6620)
* Removed getSettings from moduleEnabled so that it doesn't have to reopen the file everytime

* To Lower to while checking the theme

* color picker doesn't reopen the file

* use the generalView model config directly for FZ

* Made the same change for all the viewmodels so that they access the general view model value directly instead of opening and reading the value from a file each time

* removed unused variable

* Fix initialization in tests

* should read the file only if general settings does not exist

* Added interfaces for all the powertoys to use the generalSettings singleton class

* Runner is responding to changes in settings, only issue is that every time the general settings page is loaded the information is being read because isInitialized property could not be ignored during serialization

* All tests pass

* Settings and runner are working as expected with the settings cache

* added a null check to read from the file only when the settings process is started

* use converter to deserialize an interface

* Renamed generalSettings within the cache to be called CommonSettingsConfig

* All tests pass, had to initialize the common settings config instance

* Added few comments to newly created classes

* encapsulating load and store of general view model

* reading from file is encapsulated

* settings and runner wotk with generic singleton

* Shortcut guide works as expected

* Fancyzones, shortcutguide and power preview use the settings repository and work as expected

* referencing GeneralSettings instead of the settingsRepository<GeneralSettings> within viewmodels

* unified access to General settings and removed the IGeneralSettingsData interface

* Passing settings to viewmodel as a parameter

* removed ISettingsConfig interface from the viewmodels which are not using the singleton to access settings

* have to use ISettingsConfig to use GetSettings

* refactored tests, all tests pass

* Added test for settingsRepository that a single instance is created

* Added comments and removed unnecessary headers/code

* added settings repository tests

* moq for each settings file

* Img resizer tests pass

* General tests pass

* FancyZones tests pass

* PowerPreview tests pass

* PowerRename tests pass

* shortcut guide tests pass

* Added GetModuleName to ISettingsConfig

* unify the way the Modulename is accessed. It was redeclared in multiple places and this would cause an issue if the name is changed only in one place. All the module names are accessed using the <T>Settings.ModuleName, eg: ShortcutGuideSettings.ModuleName.

* create PTRun settings file if it does not exist

* GetFile is now a private function. Modified the logic of KBM default.json access and PT Run so that we can re-use GetSettings instead of GetFile.

* Added UpgradeSettingsConfiguration to the ISettingsConfig interface so that the settings file can be upgraded based on some condition. Presently, only the GeneralSettings file is utilizing this to change the PT Version number based on the old PT version and the current PT version that it receives from the helper function. Verified that if the PT version is lower in the general settings.json file, settings saves the file with the new version info.

* The naming for the PowerToys was inconsistent and the variables were redeclared in multiple places. To have the settings.ModuleName as the main name, all other places should refer to that name. In the tests file the module name for ImgResizer was 'ImageResizer' and not 'Image Resizer'.

* renamed lock

* Remove unnecessary GetSettingsFileNAme function. It is no longer in use because the code does not use types to create a new BasePTModule object
2020-09-23 13:20:32 -07:00
Clint Rutkas
0148669e98
[fxcop] preview handler common (#6762)
* FxCop adjustments

* initing due to change for abstract
2020-09-23 10:22:17 -07:00
Clint Rutkas
eadab13d1c added in version.prop update and the ps script 2020-09-23 08:10:42 -07:00
Arjun Balgovind
75ace74d37
[Keyboard Manager] Enabled horizontal scroll on scroll viewers and tweaked ScrollViewer layout (#6755)
* Enabled horizontal scroll on scroll viewers and tweaked layout

* Added code to constrain the minimum window sizes
2020-09-22 17:46:57 -07:00
Arjun Balgovind
1ef4c43382
[Keyboard Manager] Fix crash in Keyboard Manager by ignoring MapToSameKey warnings on loading (#6714)
* Add extra argument to ignore MapToSameKey error for Key To Shortcut mapping

* added comment
2020-09-22 13:54:53 -07:00
Clint Rutkas
c1e9f2de6a
FxCop enabled (#6758) 2020-09-22 09:14:42 -07:00
Clint Rutkas
55b36d44fa
adding in frontmatter and latex (#6711) 2020-09-22 09:10:18 -07:00
Enrico Giordani
d2201cbb79
[SG] change suppress key code (#6750) 2020-09-22 13:12:19 +02:00
Clint Rutkas
934949725b
FxCop and StyleCop for SVG thumbnail (#6757)
* FxCop work for SvgThumbnail

* enabling stylecop
2020-09-21 19:44:12 -07:00
ryanbodrug-microsoft
0f6428eed0
User/ryanbod/mock settings disk access (#6188)
* 1) Making Directory Methods private.
2) Removing the CreateDirectory / DeleteDirectory functionality from all Settings Unit Tests.

* Abstracting disk access via IIOProvider to be able to provide mocks for unit tests instead of writing to disk.   This also prevents developers who are running unit tests from interfering with the PowerToys settings on their local dev box.

* Dependency Injecting stub SettingsUtils for all tests

* Removing ISettingsUtils from constructors of objects that need to be deserialized (ColorPickerSettings/PowerLauncherSettings) as this breaks System.Text.Json

* Removing unused namespace reference

* Removing redifined mock

* As per PR feedback.  Stub Settings utils should work with any settings type if the intent is to compile / avoid null ref exceptions.

Strangely when implementing this fix it became apparent that a stub settings isn't enough, and disk access needed to be mocked.  I can't explain why the tests were passing previously.

* Leveraging GetMockIOProviderForSaveLoadExists
2020-09-21 10:14:44 -07:00
Ivan Stošić
6e89ef62e4
[Launcher] Kill the Launcher immediately (#6747)
* Kill the Launcher immediately

* Also rename the shared file
2020-09-21 13:51:30 +02:00
Ivan Stošić
b266e336b5
[Launcher] Use a keyboard hook in the runner to invoke the Launcher (#6660)
* Added a keyboard hook to the runner

* Update RootKeyboardHook

* Enable reading the whole JsonObject property

* Renamed RootKeyboardHook to CentralizedKeyboardHook

* Fixed build break, changed callback return type to bool

* Added Hotkey struct which somehow went missing

+ Cherry-pick fixes

* Reorganized the kb hook

* Basic version works

* Various fixes

* Finishing touches

* Fix potential threading issue

* int -> size_t

* Add default initializers to the Hotkey struct

* Added a suggested comment

* Unified a constant

* Use C# classes instead of native calls for sync

* Added a claryfing comment

* Use std::move

* Renamed a method

* Possible fix for compilation errors

* Fix a regression

* Show a message on failure

* Added DISABLE_LOWLEVEL_HOOK support

* Allow running Launcher as standalone

* Rename string constants
2020-09-21 12:44:16 +02:00
Arjun Balgovind
e135153c45
[Keyboard Manager] Fix focusable elements should have different names accessibility issue (#6672)
* Add listview

* Added row index to accessible names

* Cleanup rowIndex

* Fixed accessibility issue with ComboBox

* Updated comments
2020-09-18 17:12:37 -07:00
Divyansh Srivastava
28cae124d1
Nit fix in logging (#6708) 2020-09-18 13:32:28 -07:00
Clint Rutkas
94d8b4a122
rerouting to Log class vs custom logic (#6688) 2020-09-18 12:58:52 -07:00
vldmr11080
3aa7a52c21
[FancyZones] Initial improvements in FancyZones exception handling (#6063)
* Initial improvements in FancyZones exception handling

* Add callback

* Disable FancyZones if error durign loading data occurrs

* Remove logs

* Add resource strings

* Add 1sec retry when failure during initialization occurs

* Rephrase error descriptions

* Error handling during loading of module in runner

* Pass error handling on the runner

* Remove unneeded string

* Remove unnedeed changes
2020-09-18 15:18:01 +02:00
yuyoyuppe
2bc3480396 common: fix trim functions for wchar_t 2020-09-18 13:33:02 +03:00
Remy Blok
7893f387d5
[FancyZones] Configurable sensitivity radius (#6554)
* Add the setting for the Sensitivity Radius to JSON and the Editor
Use the setting when determining Zones to highligh

* Fix FanzyZones unit tests
Add test for Json upgrade

* Updated texts in FancyZone Editor
More Text to Resources / Use Resources

* Added constant for default of Sensitivity Radius

* When installing from scratch of when a new device is added set the sensitivity radius to the default.
Move all the constant values to a single namespace

* restore correct formatting

Co-authored-by: Remy Blok <remy.blok@prodware.nl>
2020-09-18 09:16:06 +02:00
Divyansh Srivastava
00187269de
handle error in Packaged program loading (#6674) 2020-09-17 16:17:02 -07:00
Roy
b3833fcf1a
[PowerToys Run] Add Suport for Commandline arguments in Program Plugin (#5791)
* Implemented possibility to add commandline arguments in the Program Plugin

* Add missing return statement inc ommandArgumentParser loop

* Fix typos

* Fix Additional Typo

* Changed -c to /c to make it a valid cmd argument

* Added small comment about importance of order in _programArgumentParsers

Co-authored-by: Roy <royvou@hotmailcom>
2020-09-17 15:39:28 -07:00
Arjun Balgovind
f19bad3761
Revert "[FxCop] Telemetry.csproj" (#6690)
* Revert "marking all warnings (#6642)"

This reverts commit b0f0940534.

* Added warning comment
2020-09-17 14:02:25 -07:00
stefansjfw
b5cc24fcff
[FancyZones] Remove migration from registry logic and delete registry data if present (#6657)
* Remove migration from registry logic

* Address PR comments
2020-09-17 20:57:44 +02:00
yuyoyuppe
d414d52156 localization: move localizable strings to .resw for runner/bootstrapper 2020-09-17 20:32:18 +03:00
Clint Rutkas
d409a71000
Getting FxCop online (#6668) 2020-09-16 12:26:58 -07:00
Clint Rutkas
0a716c253b
Upgrade nuget packages (#6641)
* upgrade mahapps

* update nlog

* all launcher packages now updated

* tests and Setting UI

* markdown

* removing unneeded DLL now from nuget update
2020-09-16 12:24:21 -07:00
Clint Rutkas
13fd6bd6e1
[FxCop] Svg preview handler (#6647)
* Adjusting namespace

* Getting FxCop working e2e
2020-09-16 12:24:07 -07:00
Clint Rutkas
b0f0940534
marking all warnings (#6642) 2020-09-16 12:23:50 -07:00
Clint Rutkas
dc284d9cbb
Clean up some unused dependencies, nlog and some newtonsoft (#6650)
* remove nlog

* removing unused referecnes to newtonsoft
2020-09-16 11:36:52 -07:00
Clint Rutkas
0a86360948
Fxcop markdown preview handler (#6646)
* migrating namespace conflict

* Fixing all errors

* removing todo

* tweak wxs
2020-09-16 11:15:34 -07:00
Divyansh Srivastava
e49900f927
Fix sync issue in SelectedItem (#6582) 2020-09-16 09:59:04 -07:00
Arjun Balgovind
5e301133ff
[Settings] Fix settings process not terminating on closing settings while minimized (#6626)
* Added code to set CoreWindow to visible on closing while minimized

* Changed to environment.exit
2020-09-16 09:47:43 -07:00
stefansjfw
3d36779e19
[FancyZones] Do not zone window if it should be maximized (#6619)
* Do not zone window if it should be maximized

* Update comment

* Remove uneeded field

* Address PR comment
2020-09-15 13:03:17 +02:00
Enrico Giordani
eaf54ca525
Fix typo in URL (#6630) 2020-09-15 12:38:34 +02:00
Arjun Balgovind
25f93e8b94
Fix for issue 3886 (#6585) 2020-09-14 13:12:02 -07:00
Arjun Balgovind
7328aa7df5
Fixed Visibility property changed invoked on clicking away from PT Run (#6588) 2020-09-14 13:10:56 -07:00
Divyansh Srivastava
d75dd71848
Fix for null reference exception (#6589) 2020-09-14 11:03:17 -07:00
Ivan Stošić
3d5c790fb6
[FZ Editor] Improved a function in GridData.cs (#6565)
* Improved a function in GridData.cs

* Allocate the extra values proportionally

* Refactor a constant
2020-09-14 10:05:28 +02:00
Clint Rutkas
5af88de27b
tweaking text and adding in headers (#6586) 2020-09-11 17:10:51 -07:00
Clint Rutkas
997a7bc60f
adding in trim (#6584) 2020-09-11 16:15:18 -07:00
Arjun Balgovind
bfbd7b53a1
Unregister key delays on closing KBM windows (#6583) 2020-09-11 15:16:34 -07:00
Alekhya
1dec80902d
unify the name as it is present in the plugin.json file (#6547) 2020-09-11 13:45:32 -07:00
Alekhya
0478d99aac
To catch URI Format Exception in PT Run (#6580)
* add a catch block for uri format exceptions

* Added link to watson crash
2020-09-11 13:04:25 -07:00
stefansjfw
db9677bb4a
[FancyZones] Do not zone window if it merges with other window (#6549)
* Do not zone window if it merges with other window (e.g. merge Chrome tab into other Chrome window

* Small move of func call

* Address PR comment

* remove include

* Address PR comment 2
2020-09-11 12:35:43 +02:00
Ivan Stošić
0e32edb603
[FancyZones] Use Ctrl+Win+Alt+arrows to Expand/shrink windows to adjacent zones (#6446)
* Added an Alt key hook

* Refactor a block of code into a method

* Again refactored existing code

* Apparently Win+Alt does not reach FancyZones

* Using Ctrl+alt instead of Win+alt for now

* It works

* Fixed VD change

* Remove unused member

* Fix compilation error

* Enable shrinking

* Fixed comments in .h files

* Remove newline

* Refactored a function into two

The next task is to simplify their code.

* Updated a comment

* Update a variable name

* Reverted to the old implementation of directional move

* More refactoring

* Remove space

* Fixed windows getting stuck

* Changed function name
2020-09-11 11:32:45 +02:00
Arjun Balgovind
82e1be2839
[Launcher] Categorize Lnk files in program plugin correctly as per the target file type (#6348)
* Updated UnregisteredApps code

* Added file type checking code and Folder and File classifications

* Added more file formats

* Removed run as admin for lnk folders

* Added script files as executable and changed hashset to case insensitive

* Removed runasadmin for generic files

* Removed FileTypes enum

* Extended ApplicationTypes enum

* Fix file format error

* Cleaned use of ApplicationType enum to public and match AppType and used ApplicationType in OnAppRenamed

* Modify tests to use ApplicationType enum

* Added tests for new App types

* Modified dummy appref

* Mock Directory.Exists and add tests for GetAppTypeFromPath

* Combined tests
2020-09-10 15:06:37 -07:00
Arjun Balgovind
ab8bec8866
[KBM] Prevent keyboard manager crash when index is not found (#6488)
* Added Sleep(5000) for repro

* Added check to prevent kbm crash for index not found

* Add more safeguards
2020-09-10 11:31:49 -07:00
Arjun Balgovind
3b8fa8b4ce
Fixed KBM shortcut remapping not working after using Japanese IME (#6450) 2020-09-10 10:46:33 -07:00
ryanbodrug-microsoft
c4cb3df306
Adding FxCop to Microsoft.Plugin.WindowWalker (#6260)
* Adding FxCop to Microsoft.Plugin.WindowWalker

* Delete WindowResult.cs -- Fix for CA1812 WindowResult is an internal class that is apparently never instantiated. If so, remove the code from the assembly. If this class is intended to contain only static members, make it static (Shared in Visual Basic).

* Fix for CA1806 UpdateOpenWindowsList calls EnumWindows but does not use the HRESULT or error code that the method returns. This could lead to unexpected behavior in error conditions or low-resource situations. Use the result in a conditional statement, assign the result to a variable, or pass it as an argument to another method.

* Fix for: CA1066 Type Microsoft.Plugin.WindowWalker.Components.InteropAndHelpers.RECT should implement IEquatable<T> because it overrides Equals

* Fix for:  CA1052 Type 'FuzzyMatching' is a static holder type but is neither static nor NotInheritable

* Suppress for CA1069 - These values are defined in
https://docs.microsoft.com/en-us/windows/win32/winmsg/extended-window-styles.

CA1069 The enum member 'WS_EX_LTRREADING' has the same constant value '0' as member 'WS_EX_LEFT'
CA1069 The enum member 'WS_EX_RIGHTSCROLLBAR' has the same constant value '0' as member 'WS_EX_LEFT'

* Supress CA1069

Code Description
CA1069 The enum member 'SWP_NOREPOSITION' has the same constant value '512' as member 'SWP_NOOWNERZORDER'
CA1069 The enum member 'SWP_FRAMECHANGED' has the same constant value '32' as member 'SWP_DRAWFRAME'

* Suprress CA1069 for ShowWindow values.  See

https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-showwindow

CA1069 The enum member 'ShowMaximized' has the same constant value '3' as member 'Maximize'

* Fix code formatting error

* Fix for CA2235: Making POINT serializable

CA2235 Field MinPosition is a member of type WINDOWPLACEMENT which is serializable but is of type Microsoft.Plugin.WindowWalker.Components.InteropAndHelpers.POINT which is not serializable
CA2235 Field MaxPosition is a member of type WINDOWPLACEMENT which is serializable but is of type Microsoft.Plugin.WindowWalker.Components.InteropAndHelpers.POINT which is not serializable

* Fix CA2235 Making RECT serializable

CA2235 Field NormalPosition is a member of type WINDOWPLACEMENT which is serializable but is of type Microsoft.Plugin.WindowWalker.Components.InteropAndHelpers.RECT which is not serializable

* Fixes for CA2101 Specify marshaling for P/Invoke string arguments.

* Fixes for CA2007 Consider calling ConfigureAwait on the awaited task

* Fixes for the following (CA1822 / CA1801):
CA1822 Member 'OnOpenWindowsUpdate' does not access instance data and can be marked as static
Code Description
CA1801 Parameter value of method add_OnOpenWindowsUpdate is never used. Remove the parameter or use it in the method body.
CA1801 Parameter value of method remove_OnOpenWindowsUpdate is never used. Remove the parameter or use it in the method body.

* Fix: CA1710 Rename OpenWindowsUpdateHandler to end in 'EventHandler'

* Fix CA1822 Member 'GetProcessIDFromWindowHandle' does not access instance data and can be marked as static

* Fix CA1062 In externally visible method 'List<int> FuzzyMatching.FindBestFuzzyMatch(string text, string searchText)', validate parameter 'searchText' is non-null before using it. If appropriate, throw an ArgumentNullException when the argument is null or add a Code Contract precondition asserting non-null argument.

* Fixes for CA1304 The behavior of 'string.ToLower()' could vary based on the current user's locale settings.

CA1304 The behavior of 'string.ToLower()' could vary based on the current user's locale settings. Replace this call in 'FuzzyMatching.FindBestFuzzyMatch(string, string)' with a call to 'string.ToLower(CultureInfo)'.

Code Description
CA1304 The behavior of 'string.ToLower()' could vary based on the current user's locale settings. Replace this call in 'FuzzyMatching.FindBestFuzzyMatch(string, string)' with a call to 'string.ToLower(CultureInfo)'.

* Supressing warning for CA1814: Prefer jagged arrays over multidimensional however this might be something to consider if needing to optimize the window walker search.

* Fix: CA1062 In externally visible method 'List<List<int>> FuzzyMatching.GetAllMatchIndexes(bool[,] matches)', validate parameter 'matches' is non-null before using it. If appropriate, throw an ArgumentNullException when the argument is null or add a Code Contract precondition asserting non-null argument.

* Fix for CA1062 In externally visible method 'int FuzzyMatching.CalculateScoreForMatches(List<int> matches)', validate parameter 'matches' is non-null before using it. If appropriate, throw an ArgumentNullException when the argument is null or add a Code Contract precondition asserting non-null argument.

* Fixes for CA1806 Calls x...  but does not use the HRESULT or error code that the method returns. This could lead to unexpected behavior in error conditions or low-resource situations. Use the result in a conditional statement, assign the result to a variable, or pass it as an argument to another method.

Using discard for methods that return void, and checking the hresult before returning parameters.

* Fix for CA1820 Test for empty strings using 'string.Length' property or 'string.IsNullOrEmpty' method instead of an Equality check

* Supress CA1031 Modify 'get_WindowIcon' to catch a more specific allowed exception type, or rethrow the exception

* Code Description
CA1062 In externally visible method 'List<Result> Main.Query(Query query)', validate parameter 'query' is non-null before using it. If appropriate, throw an ArgumentNullException when the argument is null or add a Code Contract precondition asserting non-null argument.

* Fixes For CA1304 The behavior of 'string.ToUpper()' could vary based on the current user's locale settings.

CA1304 The behavior of 'string.ToLower()' could vary based on the current user's locale settings. Replace this call in 'SearchController.SearchText.set' with a call to 'string.ToLower(CultureInfo)'.
CA1304 The behavior of 'string.ToLower()' could vary based on the current user's locale settings. Replace this call in 'Window.ProcessName.get' with a call to 'string.ToLower(CultureInfo)'.
CA1304 The behavior of 'string.ToLower()' could vary based on the current user's locale settings. Replace this call in 'Window.SwitchToWindow()' with a call to 'string.ToLower(CultureInfo)'.
CA1304 The behavior of 'string.ToUpper()' could vary based on the current user's locale settings. Replace this call in 'Window.ToString()' with a call to 'string.ToUpper(CultureInfo)'.
CA1307 The behavior of 'string.Equals(string?)' could vary based on the current user's locale settings. Replace this call in 'Microsoft.Plugin.WindowWalker.Components.Window.SwitchToWindow()' with a call to 'string.Equals(string?, System.StringComparison)'.

* Fix: CA1710 Rename SearchResultUpdateHandler to end in 'EventHandler'

* Fix CA1060 Move pinvokes to native methods class

* Fix: CS0067 The event 'OpenWindows.OnOpenWindowsUpdateEventHandler' is never used

1) Remove SearchController::OpenWindowsUpdateHandler(object sender, SearchResultUpdateEventArgs e) as it wasn't being called and was redundant with Update Search Text.
2) In Main.cs calling UpdateOpenWindowsList before UpdateSearchText so that the latest enumerated windows will be called.
3) Removing unused OnOpenWindowsUpdateEventHandler and related code.

* Revert "Fixes for CA2101 Specify marshaling for P/Invoke string arguments."

This reverts commit b3dfe07915.

* Fixing CA2101 by turning off best fit mapping for methods that require ANSI marshalling.

See: https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2101?view=vs-2019

* Previous fix for CA1806 misunderstood int result as hresult.  The actual return value is number of characters written.
NativeMethods.GetWindowText(hwnd, titleBuffer, sizeOfTitle);

* Previous fix for CA1806 misunderstood int result as hresult.  The actual return value is number of characters written.

NativeMethods.GetClassName(Hwnd, windowClassName, windowClassName.MaxCapacity);

* Removing unused window code.  This was done instead of validating fxcop changes in WindowIcon.

* Fixing typos in Window.cs (charachter -> character)
2020-09-10 09:44:22 -07:00
Alekhya
efd5c33a92
set object before using it (#6497) 2020-09-10 09:44:10 -07:00
Niels Laute
f589103f5d
Change searchbox order to make text selectable (#6400)
Co-authored-by: Niels Laute <niels9001@hotmail.com>
2020-09-10 09:42:20 -07:00
vldmr11080
19175e9bde
Introduce several fallback scenarios when obtaining GUID for current virtual desktop (#6534) 2020-09-10 14:42:36 +02:00
P-Storm
3137aaa660
Create unit tests for Calculator plugin (#6356)
* Refactored logic and made it unit testable

* Changes after code review

* Added to build steps, and modified bracket to new class with unittest. Validates complexer cases now.

Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-09-09 20:01:30 -07:00
Clint Rutkas
cfda69a120
FxCop with ColorPicker (#6464)
* fxcop fixes

* more fixes, not done yet

* supressing 1031 and ca2000 since we are expressly disposing this correctly

* catching a possible crash due to null ref if run twice

* addressing feedback
2020-09-09 17:08:37 -07:00
Clint Rutkas
1027b7de72
Enabling FxCop on tests (#6481) 2020-09-09 15:33:18 -07:00
Arjun Balgovind
fb1888f01f
Add in verbose error message and telemetry for SetWindowsHookEx failure (#6454)
* Updated error message when SetWindowsHookEx fails to show correct error message

* Added telemetry for exception in SG, FZ and KBM

* Rename exception to error
2020-09-09 14:27:40 -07:00
Divyansh Srivastava
f61e9d389f
catch unhandled FileNotFoundException exception (#6456) 2020-09-09 11:33:28 -07:00
dependabot[bot]
936b02865f
Bump http-proxy from 1.17.0 to 1.18.1 in /src/settings-web (#6455)
Bumps [http-proxy](https://github.com/http-party/node-http-proxy) from 1.17.0 to 1.18.1.
- [Release notes](https://github.com/http-party/node-http-proxy/releases)
- [Changelog](https://github.com/http-party/node-http-proxy/blob/master/CHANGELOG.md)
- [Commits](https://github.com/http-party/node-http-proxy/compare/1.17.0...1.18.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-09-09 16:14:58 +02:00
yuyoyuppe
cbd3516fc4 installer: reduce notification spam 2020-09-09 12:50:31 +03:00
yuyoyuppe
c2d6f740a1 bootstrapper: handle the unhandled 2020-09-09 12:50:31 +03:00
Niels Laute
305a04ce69
[Settings] NumberBox headers fixes (#6227)
* Update from master

* Updated Numberbox headers
2020-09-08 15:28:57 -07:00
Arjun Balgovind
fdd7d6afa4
Add in missing telemetry for Keyboard Manager usage (#6393)
* Added key remap invoked telemetry event

* Added queryperformance call

* Added in telemetry for key and shortcut remaps

* Removed redundant if check
2020-09-08 14:40:02 -07:00
Alekhya
1a51f77fce
Fix KBM Accessibility issues (#6379)
* Added an accessible name for the combo box

* Add name for the type shortcut button

* Add accessible name for the add new remapping button in both key remapping as well as shortcut remapping windows

* Set accessible names for the delete button

* Set the accessible name to the remapped to icon

* Fix the font icon issue faced while using narrator

* Fix accessible name for Add shortcut remapping button

* Set the accessible name for the target app text box when it loses focus

* fix comment
2020-09-08 12:24:59 -07:00
Arjun Balgovind
8ea8db7994
[PowerToys Run] Remove unused wox resources and move hardcoded strings to resx file (#6181)
* Removed xaml files, added resx file and removed references for PowerLauncher project

* Added resx file for wox.plugin

* Moved Calculator resources to resx

* Migrated resources for Folder and Indexer plugins

* Migrated resources for Program and Shell plugin

* Migrated resources for URI and Window Walker

* Removed GetTranslation, tests need to be refactored

* Removed internationalization classes

* Removed Wox.Core.Resource references

* Fixed Programs plugin tests

* Fixed tests

* Removed language xaml files from installer

* Added locProject.json files

* Fixed resource not found error

* Remove unused strings from PowerLauncher

* Removed all unused strings

* Reverted addition of resx file for Wox.Plugin

* Added more resources for Folder plugin

* Added resources for Folder and Indexer plugin

* Added resources for Program, Shell, Uri and WW plugins

* Changed string from Wox to PT Run

* managed common files
2020-09-08 11:51:24 -07:00
Divyansh Srivastava
cd906b0a6f
Corrected querytext display on action keyword (#6341)
* Corrected querytexdisplay on action keyword

* Added tests for UpdateResultWithActionKeyword
2020-09-08 10:32:01 -07:00
Alekhya
85fa644aca
Fix KBM Settings page Property related and screen reader Accessibility issues (#6289)
* Add accessible names for the KBM key remapping list and list item

* Add accessible name for the shortcut list item

* Add accessible name for shortcut remapping list

* Added accessible names to all icons

* Add accessible name for image

* Fix font icon narrator issue
2020-09-08 10:25:53 -07:00
Divyansh Srivastava
52a06b5cdc
[PT Run] Mitigate JSON Deserialization exception (#6295)
* Add error reporting window on deserialisation error

* Add message box to show launcher errors

* Change report window to messagebox

* nit fix in error window

* Localized string for error window

* update messagebox interface

* Correct ShowMessageBox argument order
2020-09-08 10:04:17 -07:00
vldmr11080
13426eac50
[FancyZones] Validate zone rect before adding it into layout (#6249)
* Validate zone rect before adding it into layout

* Rename variables for better code readability
2020-09-08 12:06:54 +02:00
Enrico Giordani
c5f90272d1
ImageResizer new icon (#6443) 2020-09-08 11:29:51 +02:00
stefansjfw
3c76942799
[FancyZones] Update 'span zones across monitors' feature description and add message box warning accordingly (#6381)
* Update span accross monitors feature description in Settings App

* Add warning if scalings are different

* Address PR comments

* Address comment
2020-09-07 12:24:13 +02:00
Divyansh Srivastava
a0eaf077de
[Pt Run] Show context menu for first folder plugin result (#6301)
* Added context menu to first folder result

* Added context menu to first folder result

* Add localization for string in folder plugin

* Fixed issue with context menu not showing on first selected item

* Add exception  logging
2020-09-04 15:12:04 -07:00
Arjun Balgovind
726f94e2a2
[Settings] Fix tabbing issues on KBM settings page (#6304)
* Removed listview items from tab ordering

* Removed tabstops on key/shortcut item controls to prevent double tab requirement
2020-09-04 12:42:41 -07:00
stefansjfw
78edaf5edc
[FancyZones] Set 3-zones PriorityGrid as default layout (#6248)
* 3-zones Priority Grid as default layout

* Update tests

* Address PR comments
2020-09-04 16:37:06 +02:00
Seraphima Zykova
570065175c
[Settings] Temporary string showing the latest available version (#6254) 2020-09-04 11:56:52 +03:00
stefansjfw
e84a293642
Fix span accross monitors feature (#6335) 2020-09-04 10:11:05 +02:00
martinchrzan
6e898ae52d
Added pixel reveal effect, increased max zoom level to 4, added rounded corners to main and zoom window (#6242) 2020-09-03 23:31:27 +02:00
Arjun Balgovind
288d929477
[Settings] Changed ImageSize class to parse as double instead of int (#6299)
* Changed ImageSize class to parse as double instead of int

* Tweaked fix to resolve empty ImageResizer box fix
2020-09-03 13:43:55 -07:00
Jeremy Wu
807fbd4d89
fix missing fragment portion of LocalPath (#6257) 2020-09-03 12:46:34 -07:00
ryanbodrug-microsoft
6ce47e5cd9
Adding fxcop to PowerLauncher.TelemetryProject (#6259) 2020-09-03 10:44:51 -07:00
Clint Rutkas
712d5fbfa7
fixing the fody warning (#6164)
* fixing the fody warning

* removing the ignored item from the installer
2020-09-03 09:49:28 -07:00
Seraphima Zykova
c9855a2671
[FancyZones] Fixed type cast warning (#6311) 2020-09-03 17:50:49 +03:00
Enrico Giordani
64ee0015d1
[chore] fix line endings (#6307) 2020-09-03 11:44:46 +02:00
Arjun Balgovind
1b598ad87e
[Localization] Move PowerToys Run string resources from xaml files to resx (#6165)
* Removed xaml files, added resx file and removed references for PowerLauncher project

* Added resx file for wox.plugin

* Moved Calculator resources to resx

* Migrated resources for Folder and Indexer plugins

* Migrated resources for Program and Shell plugin

* Migrated resources for URI and Window Walker

* Removed GetTranslation, tests need to be refactored

* Removed internationalization classes

* Removed Wox.Core.Resource references

* Fixed Programs plugin tests

* Fixed tests

* Removed language xaml files from installer

* Added locProject.json files

* Fixed resource not found error

* Reverted addition of resx file for Wox.Plugin
2020-09-02 15:24:59 -07:00
Alekhya
c9f536c635
fix for argument out of range exception (#6269) 2020-09-02 13:39:57 -07:00
Divyansh Srivastava
742f4fe36d
[Pt Run] Narrator support for result view navigation (#6146)
* Screen reader detecting List view

* Fixed narrator text for listview items and context menu items

* Renamed custom textbox to a more meanigful name

* Renamed custom textbox to a more meanigful name

* Fix formatting of LauncherControl.xaml

* Added support to control multiple elements
2020-09-02 13:34:07 -07:00
Enrico Giordani
06267f5a03
Now working on 0.21.2 (#6286) 2020-09-02 10:18:14 -07:00
Enrico Giordani
824bec2784
Update version to 0.21.1 (#6284) 2020-09-02 09:57:55 -07:00
Seraphima Zykova
cb81f7b057
[FancyZones] Convert ARGB color values to RGB (#6277) 2020-09-02 19:27:35 +03:00
Seraphima Zykova
ce43b10b5b
[FancyZones] HEX to RGB util (#6275) 2020-09-02 18:34:17 +03:00
Arjun Balgovind
0349383d08
[PowerToys Run] Fix error reporting window for exceptions that are not on the dispatcher thread (#6221)
* Possible fix for dispatcher error

* Revert changes on other files
2020-08-31 10:22:00 -07:00
Divyansh Srivastava
777e1dc48c
Fix color issue in search box (#6222) 2020-08-28 17:18:46 -07:00
Divyansh Srivastava
fe8727bd94
Fix issue with autocomplete text remaining on clearing query (#6220) 2020-08-28 14:58:57 -07:00
Enrico Giordani
6a531ca57c
Update version to 0.21.0 (#6219) 2020-08-28 20:57:03 +02:00
yuyoyuppe
fc4ac803aa common: do not accept invalid input in VersionHelper and add negative unit tests 2020-08-28 16:37:12 +03:00
yuyoyuppe
870f1095cd setup: add --help and --no_dotnet commands 2020-08-28 16:37:12 +03:00
yuyoyuppe
4e969a3701 bootstrapper: do not specify patch version of .net core in the notification msgs 2020-08-28 16:37:12 +03:00
stefansjfw
0a603449ad
[FancyZones] Enable to manually zone child windows (#6182)
* Enable to manually zone child windows

* Refactor IsInterestingWindow in 2 separate functions

* Remove enum
2020-08-28 15:00:21 +02:00
Enrico Giordani
d51640c2f0
[PowerRename] fix build warning (#6210)
PowerRenameUWPUI uses the resources from powerrename\dll\Resources.resx
2020-08-28 14:45:24 +02:00
Ivan Stošić
be8695777c
Fixed a stack overflow (#6212)
Credits to @gurnec for proposing the fix.
2020-08-28 13:54:59 +02:00
Enrico Giordani
eb825ae619
[FancyZones] fix warning (#6203) 2020-08-28 11:30:03 +02:00
Arjun Balgovind
07dfa6f296
Fix runner crashing on launching Keyboard Manager UI (#6185)
* Added maxVersionTested back to the manifest

* Updated comment with link to docs
2020-08-26 15:57:25 -07:00
Ivan Stošić
cb52cb2549
Improved the KB Hook in Color Picker (#6175)
* Improved the KB Hook in Color Picker

* Update KeyboardMonitor.cs

* Further simplify a method

* Using var

* Update KeyboardMonitor.cs

Add return;
2020-08-26 18:21:22 +02:00
Enrico Giordani
26b73b0745
[ColorPicker] proper Trace::UnregisterProvider(); (#6155) 2020-08-26 18:15:09 +02:00
Chris Davis
fead0c5ad9
Allow embedded images in SVGs to be displayed (#6163)
* Add DLIMAGES to WebBrowserExt ambient control flags to allow display of img links in SVGs.  We still specify FORCEOFFLINE so we are not actually performing a download.  This is to target SVGs with xlink base64 encoded data.

* Fix unit test
2020-08-26 09:06:42 -07:00
Arjun Balgovind
3bd6c363de
Added missing ! to condition check (#6162) 2020-08-25 12:07:17 -07:00
stefansjfw
48b6654ad2
Introduce ZoneWindowDrawing files and move stuff to better place (#6142) 2020-08-25 18:55:29 +02:00
ryanbodrug-microsoft
2075f9fa71
Comparing exepected vs actual json strings. This fixes two issues. (#6145)
1) the same variables are being compared against each other.
2) BasePTSettingsTest doesn't override equals to Equals compares the objects. This change compares the json strings directly.
2020-08-25 09:07:44 -07:00
Seraphima Zykova
96fdb6169a
Warning fix: __NULL_IMPORT_DESCRIPTOR already defined in Pathcch.lib (#6150) 2020-08-25 12:52:25 +03:00
Seraphima Zykova
6d47a5477a
Warning fix: C++/CLI mode does not support C++ versions newer than C++17 (#5910) 2020-08-25 12:21:30 +03:00
Mehmet Murat Akburak
d3b80b26e3
[PowerRename] Add Filtering Feature (#6017)
* Implement basic functionality

* Change approach.
move filter controls to manager
edit redrawing to always work with new GetVisibleItemCount() and GetVisibleItemByIndex() calls

* Fix performance issues. Some refactoring.

* Handle toggleAll correctly

* Handle dangling elements when filter is on

Make an item visible if it has at least one visible subitem

* Support filtering for selected and shouldRename

* Refactor for readability, remove useless member from PowerRenameUI

* Change variable names in PowerRenameUI for clarity

Use wrapper function RedrawItems() and SetItemCount() for consistency

* Handle result value properly in getVisibleItemByIndex()

* Add FlagsApplicable filter

* Add visual indication of filters

* Improve performance

Check if no filter is selected
Call SetItemCount() only when necessary

* Refactor for readability

* Get lock in setVisible()

* Change function names to camel case

* Change function names to start with uppercase

* Change filter behaviour when search area is empty

Show all elements when search area is empty and ShouldRename filter is selected
Avoid warnings

* Resolve conflicts
2020-08-25 08:22:05 +03:00
Arjun Balgovind
3ede1a0b53
[Localization] Migrate resources to resx for PowerRename (#6112)
* Added localization code to pipeline and created one LocProject json for Settings

* Fixed typo

* Reordered nuget source

* Moved nuget install to restore step

* Added FZ.rc file to LocProj

* Added FZ resx file and modified rc file

* Fixed file names

* Changed to check folder for LocProject files

* Updated folder

* Changed directory

* Changed to src directory

* Changed language set and name format, removed rc file localization

* Added all projects with resx/resw files

* Added newline to end of file

* Removed nuget source as it is not used

* Updated comments

* Updated keyboard manager to use resx file

* Tweaked resources.resx and added it to project files

* Added comments and added in string table to resx script

* Remove change from bad merge

* Fix syntax error in convert stringtable

* Changed file type to None

* Migrated color picker's resources

* Migrated resources for Microsoft.Launcher

* Migrated resources for fancy zones

* Revert fancyzones changes

* Migrated resources for ImageResizer and modified script to add language specific code

* Added try catch and checks for modification to avoid unnecessary file creation

* Changed tab insertion to 4 spaces to avoid mixed file types in rc file

* Migrated resources for power preview project

* Added LocProject.json file for 5 projects

* added resgen exception check

* Moved non-localizable strings out of resx for powerpreview

* Move out hardcoded strings from dialog box and set them at runtime from string table

* Migrated resources for powerrename

* Added locproj

* Added missing ImageBase extern declaration

* Added build script in UWP UI project since PowerRenameExt is not referenced

* Resolved merge conflicts
2020-08-24 17:51:48 -07:00
Arjun Balgovind
aebd7657ef
[Localization] Migrate resources to resx for FancyZones (#6106)
* Added localization code to pipeline and created one LocProject json for Settings

* Fixed typo

* Reordered nuget source

* Moved nuget install to restore step

* Added FZ.rc file to LocProj

* Added FZ resx file and modified rc file
2020-08-24 17:50:41 -07:00
Arjun Balgovind
15938a12be
[Localization] Migrate resources to resx for Shortcut Guide (#6104)
* Added localization code to pipeline and created one LocProject json for Settings

* Fixed typo

* Reordered nuget source

* Moved nuget install to restore step

* Added FZ.rc file to LocProj

* Added FZ resx file and modified rc file

* Fixed file names

* Changed to check folder for LocProject files

* Updated folder

* Changed directory

* Changed to src directory

* Changed language set and name format, removed rc file localization

* Added all projects with resx/resw files

* Added newline to end of file

* Removed nuget source as it is not used

* Updated comments

* Updated keyboard manager to use resx file

* Tweaked resources.resx and added it to project files

* Added comments and added in string table to resx script

* Remove change from bad merge

* Fix syntax error in convert stringtable

* Changed file type to None

* Migrated color picker's resources

* Migrated resources for Microsoft.Launcher

* Migrated resources for fancy zones

* Revert fancyzones changes

* Migrated resources for ImageResizer and modified script to add language specific code

* Added try catch and checks for modification to avoid unnecessary file creation

* Changed tab insertion to 4 spaces to avoid mixed file types in rc file

* Migrated resources for power preview project

* Added LocProject.json file for 5 projects

* added resgen exception check

* Moved non-localizable strings out of resx for powerpreview

* Migrated shortcut guide resources to resx

* Added LocProject.json
2020-08-24 17:49:28 -07:00
Arjun Balgovind
f2cfd90c46
[Localization] Move rc files to resx (#6057)
* Added localization code to pipeline and created one LocProject json for Settings

* Fixed typo

* Reordered nuget source

* Moved nuget install to restore step

* Added FZ.rc file to LocProj

* Added FZ resx file and modified rc file

* Fixed file names

* Changed to check folder for LocProject files

* Updated folder

* Changed directory

* Changed to src directory

* Changed language set and name format, removed rc file localization

* Added all projects with resx/resw files

* Added newline to end of file

* Removed nuget source as it is not used

* Updated comments

* Updated keyboard manager to use resx file

* Tweaked resources.resx and added it to project files

* Added comments and added in string table to resx script

* Remove change from bad merge

* Fix syntax error in convert stringtable

* Changed file type to None

* Migrated color picker's resources

* Migrated resources for Microsoft.Launcher

* Migrated resources for fancy zones

* Revert fancyzones changes

* Migrated resources for ImageResizer and modified script to add language specific code

* Added try catch and checks for modification to avoid unnecessary file creation

* Changed tab insertion to 4 spaces to avoid mixed file types in rc file

* Migrated resources for power preview project

* Added LocProject.json file for 5 projects

* added resgen exception check

* Moved non-localizable strings out of resx for powerpreview
2020-08-24 15:10:50 -07:00
Divyansh Srivastava
f3a55d96f5
Remove the code for saving/writing program plugin cache (#6107) 2020-08-24 10:50:54 -07:00
Alekhya
392ca87dab
Fix Accessibility issues of the shortcut guide settings page (#6091)
* set the labeled by property of number box to point to the textblock heading so that 'Press duration before showing (ms)' string is read when the number box is highlighted

* Added comments on the accessibility issues that are dependent on the winui radiobuttons control

* Added information to the shortcut guide image on the right, it previously said only the word graphic
2020-08-24 10:48:45 -07:00
Alekhya
ff48421e4f
Add info about the color picker image (#6097) 2020-08-24 10:48:35 -07:00
Alekhya
f6579184a2
Add information about the image (#6099) 2020-08-24 10:48:24 -07:00
Alekhya
c0c68f6acd
Fix Accessibility issues in the PowerRename settings page (#6101)
* add automation property to number box

* Set the automation property for the image
2020-08-24 10:48:12 -07:00
Alekhya
f2fd376363
Fix Accessibility issues of the Image Resizer settings page (#6109)
* Added an automation name to the custom list view

* Added an automation property for the text box

* changed the name to 'Configuration'

* Added an automation property for the combo box

* Add automation property for number box

* added a name for the times symbol

* Added the height name automation property

* Add automation property for image resizer size combo box

* Add name and uid for button

* Add automation name for the grouping of list views

* Add automation property label for number box

* Add name for the filename format edit box

* Added more information to the image
2020-08-24 10:47:59 -07:00
stefansjfw
9999a2b126
Refactor common and fancyzones/utils (#6073)
* Move module-specific functions to module

* Refactor FZ utils

* Remove 'zonable' from FancyZonesWindowInfo

* Address PR comments

* Address PR comments

* Fix stuff after rebasing
2020-08-24 19:38:15 +02:00
Enrico Giordani
2817bf4d62
[FancyZones] fix warnings (#6095)
unified data type to size_t in all methods that process the zone index set
2020-08-24 14:39:34 +02:00
Seraphima Zykova
845bb466c6
[FancyZones] Shift + StickyKeys behavior fix (#6039) 2020-08-24 10:19:39 +03:00
Clint Rutkas
f64df97652
adding in FxCop to Svg tests (#6111) 2020-08-21 17:23:42 -07:00
Divyansh Srivastava
9c6b2c3e81
Display colored icons for packaged apps (#5923)
* Added wox code for tiling

* nit fixes in plating function

* Added feature to plate images based on theme

* Improve code readability

* added altform based paths

* Error handling in fetching logo

* Re add fix sequence empty exception on calling max in program plugin

* Move path and logo setting code to setIcon function

* Add corner radius to packaged apps icon

* Revert "Add corner radius to packaged apps icon"

This reverts commit 9be496e662.
2020-08-21 13:39:08 -07:00
Clint Rutkas
83e8799610
init checkin (#6100) 2020-08-21 12:40:31 -07:00
Alekhya
80f8c0399b
To remove the condition that space is needed after the Action keyword (#6003)
* Returning individual queries for each plugin

* Changed cancellation token from Query type to directly using the rawQuery

* Changed the way we get the plugins for which we execute the query

* updated UpdateResultView to take a string instead of query

* Changed the way we set a query for each plugin

* removed todo comment

* global plugins are added as a part of the query builder

* Fix for plugin.json of Folder plugin being copied into the shell plugin

* >,< and : are not allowed in file paths and indexer creates a query which searches compares if a file name is greater than or lesser than the query

* Reformatted the regex

* catching the exception

* fixed existing tests

* modified it so that it works with action keyword as well as action keywords

* Added unit tests for non global plugins

* fixed test

* add back whitespace that was removed by mistake

* fix regex

* modified the cold start query

* remove extra condition

* terms being modified as expected

* used key value pairs to iterate through the dictionary

* renamed variable

* added check for an empty dictionary

* remove : because it may appear in the file path

* fix some whitespace warnings that were being treated as errors
2020-08-21 12:21:42 -07:00
Alekhya
f6b5840e0e
Fix Accessibility issues of the FancyZones Settings page (#6045)
* Added automation property for the button

* Added an automation property name for the glyph

* added name automation property for the shortcut window

* fixed the name null for zone highlight button

* fixed the name for the inactive color dropdown

* fixed the accessibility issue with the border color downdown button

* fixed the issue with dropdowb buttons

* add description to the image

* Capitalize Z otherwise it reads it in an expected way

* made the naming generic as it the custom window is not only specific to fancyzones but is also used by colorpicker and PTRun to set their shortcut
2020-08-21 12:21:23 -07:00
Alekhya
b5dec2e935
Fix Accessibility Issues of PT Run settings page (#6090)
* label number box

* Added information to the PTRun image on the right
2020-08-21 12:21:15 -07:00
ryanbodrug-microsoft
79bb68d784
User/ryanbod/shell plugin fxcop (#6043)
* Enabling FxCop static analysis.

* Fixes for CA2227 Change 'Count' to be read-only by removing the property setter.
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2227?view=vs-2019

* Fix for:  CA1822: Mark members as static
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1822?view=vs-2019

* Fix for CA1805: Do not initialize unnecessarily.
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1805?view=vs-2019

* Fix for: Error CA1724 The type name Settings conflicts in whole or in part with the namespace name 'Microsoft.PowerToys.Settings'. Change either name to eliminate the conflict. Microsoft.Plugin.Shell C:\repos\powertoys\src\modules\launcher\Plugins\Microsoft.Plugin.Shell\Settings.cs 9 Active

* Severity Code Description Project File Line Suppression State
Error CA1724 The type name Settings conflicts in whole or in part with the namespace name 'Microsoft.PowerToys.Settings'. Change either name to eliminate the conflict. Microsoft.Plugin.Shell C:\repos\powertoys\src\modules\launcher\Plugins\Microsoft.Plugin.Shell\Settings.cs 9 Active

* Fix for CA1307: Specify StringComparison & CA1305: Specify IFormatProvider
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1307?view=vs-2019
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1305?view=vs-2019

* Fix for CA1062: Validate arguments of public methods
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1062?view=vs-2019

* Suppressing CA1031 Modify 'Query' to catch a more specific allowed exception type, or rethrow the exception'
2020-08-21 12:10:41 -07:00
Ivan Stošić
976116a012
Win arrows revisited (#5932)
* Added the setting

* Refactored existing code, the main feature isn't implemented yet

* Renamed a method

* Updated a comment in IZoneWindow

* Added the zone selection algorithm, didn't test it

* Basic features work

* Single monitor cycling works

* Seems that the feature works well

* Polished the settings page

* Rebase fix

* Fixed a null pointer dereference

* Use classic if syntax

* Fixed bad indentation

How did these lines unindent themselves?

* Removed TODO comment

* Rebase fix

* Another rebase fix
2020-08-21 12:53:03 +02:00
Seraphima Zykova
64c51a49a0
[FancyZones] Failing unit tests update (#6065) 2020-08-21 08:56:25 +03:00
Clint Rutkas
cc0b808962
Blurry Text for PT Run improvements (#6049)
* Checking in adjustments based off @anuthadev pr's

* Forcing an improvement on the magnifier glass

* removing whitespace
2020-08-20 21:45:55 -07:00
Seraphima Zykova
9b567f9ba3
[FancyZones] capture strong_this (#6066) 2020-08-20 19:55:41 +03:00
Enrico Giordani
9a36b005a1
[Shortcut Guide] fix Virtual-Key codes range (#6025) 2020-08-20 12:24:06 +02:00
ryanbodrug-microsoft
2390368d03
Fix for Crash due to System.AccessViolationException when calling OleDBSearch from multiple threads. (#6052)
* Removing non thread safe member variables, as well as the check to ensure that they have been disposed.

* Removing 'ExecuteQuery_ShouldDisposeAllConnections_AfterFunctionCall'.

This call previously required the use of member variables that were not thread safe.   There is no reason to share this state across threads.  Arguably this test verifies an internal implementation detail and is not suitable for a unit test anyway.
2020-08-19 17:28:19 -07:00
Mehmet Murat Akburak
64106cba82
[PowerRename] Using File Attributes Update (#5250)
* Use only fff for milliseconds

* Refactor

* Handle double $ signs.
Move isFileAttributes check to Helpers.
Move File Attributes to perform before regex operation

* Fix typo

* Format date/time test

* Disable problematic features. Add comments

* Fix month/day names

* Add tests

* Add line between tests

* Add local month/day names support

* Make sure month/date names are capitalized

* Fix formatting
2020-08-20 02:53:09 +03:00
Divyansh Srivastava
69cb20e1cd
Re add fix sequence empty exception on calling max in program plugin (#6054) 2020-08-19 16:16:45 -07:00
Arjun Balgovind
2a7bf7fb5b
[Localization] Add localization step to pipeline and enable localization on C# projects with resx/resw resource files (#6033)
* Added localization code to pipeline and created one LocProject json for Settings

* Fixed typo

* Reordered nuget source

* Moved nuget install to restore step

* Added FZ.rc file to LocProj

* Added FZ resx file and modified rc file

* Fixed file names

* Changed to check folder for LocProject files

* Updated folder

* Changed directory

* Changed to src directory

* Changed language set and name format, removed rc file localization

* Added all projects with resx/resw files

* Added newline to end of file

* Removed nuget source as it is not used

* Updated comments

* Fixed formatting of json file

* Move loc step to end
2020-08-19 16:10:15 -07:00
Clint Rutkas
dc744f236e
[warningsAsErrors] Getting settings online (#6053)
* getting everything to compile

* fixing json
2020-08-19 15:59:10 -07:00
Divyansh Srivastava
9724afd9ec
Run UI contrast accessibility (#6027)
* Fix contrast ration for SecondaryTextForeground brush

* Improve contrast for context menu button
2020-08-19 11:38:49 -07:00
Alekhya
34e7467d16
Fix accessibility issues related to the General Settings page (#6034)
* grouped radio buttons together

* grouping radio buttons together

* the word version is now read along with the version number

* Information regarding the image is read

* added a comment with the link to the issue in the winui repository
2020-08-19 11:29:13 -07:00
stefansjfw
7eccb6fc7a
Delete custom layout if malformed (#6011) 2020-08-19 18:12:57 +02:00
Nkateko
0445e89747
[Settings] Migrate PT Run Settings (#5768)
* added MSTest project

* Migrated PT Run Tests

* reverted changes to xaml file

* fixed Sttings.UI.csproj file

* added parameter for default key code
2020-08-19 08:12:07 -07:00
Nkateko
953ab958d5
[Settings] Migrate Fancy Zones Settings Tests (#5762)
* added MSTest project

* [Settings] Migrate Fancy Zones Settings Tests

* fixed errors

* reverted changes to xaml file

* updated varibale for test folder

* add ignore case flag

* fixed Sttings.UI.csproj file

* fixed Sttings.UI.csproj file
2020-08-18 14:46:32 -07:00
Nkateko
5e13152c73
[Settings] Migrated Image Resizer Tests (#5765)
* added MSTest project

* Migrated Image Resizer Tests

* fixed links

* removed exception
2020-08-18 13:43:58 -07:00
ryanbodrug-microsoft
8c98c7df29
attempting to run CI unittests for .netcore and .netframework projects (#5886)
* attempting to run CI unittests as seperate passes for .netframework and .netcore, based on assemblies.

* Mocking CSearchManager to avoid the following exception running in CI.

Retrieving the COM class factory for component with CLSID {7D096C5F-AC08-4F1F-BEB7-5C22C517CE39} failed due to the following error: 80070422 The service cannot be started, either because it is disabled or because it has no enabled devices associated with it. (0x80070422).

* Setting proper connection string for unit test.

* Mocking sqlQuery with FilePath vs m*

* Temporarily Ignoring test that is throwing exception in CI.
2020-08-18 13:19:35 -07:00
Divyansh Srivastava
cedc4f710e
Catch exception in save method for json class (#5950)
* Catch exception in save method for json class

* Update error message

* Correct error logging format

* Catch IO exception
2020-08-18 10:50:16 -07:00
Seraphima Zykova
13d61bd866
WinAppDriver tests update (#5882)
* tray button fix
* settings closing changed
* ignore old settings tests
* changed test init
* changed launch
* separated app history file
* select enabled modules on launch
2020-08-18 12:23:43 +03:00
Nkateko
c6c9839208
[Settings] KBM Migrated KBM Settings Tests (#5821)
* added MSTest project

* enabled settings tests run in the build pipeline

* migrated KBM settings

* fixed typo

* moved the callback function initialization to the top

* fixed build
2020-08-17 15:00:19 -07:00
Clint Rutkas
2ff439dc47
fixing warnings, per ryan suggestion, suprressing warning now. we'll revisit the if debug blocks later (#6010) 2020-08-17 14:52:27 -07:00
Niels Laute
dad8cbecc1
[Launcher] ReportWindow redesign and theming support (#5790)
* Updated adaptive trigger behavior

* Fixed wrapping for KBM subtitle textblock

* Fix

* Theme support for ReportWindow

* Fix

* Fix

* Spacing issue fix

* Revert "Fix"

This reverts commit 8b2812e2de.

* Revert "Fixed wrapping for KBM subtitle textblock"

This reverts commit aa9ec54121.

* Revert "Updated adaptive trigger behavior"

This reverts commit e6f4ed27a1.

* Update ReportWindow.xaml.cs

* Update ReportWindow.xaml.cs

* Update ReportWindow.xaml.cs

* Removed redundant code, fixed trailing issue

Co-authored-by: Niels Laute <niels9001@hotmail.com>
2020-08-17 13:48:54 -07:00
Arjun Balgovind
8f8b200f24
Move hardcoded strings in Keyboard Manager projects to rc file (#5921)
* moved all strings in c++ side to rc file

* Fixed formatting
2020-08-17 13:46:50 -07:00
Clint Rutkas
8dec9d5fe9
Fixing color picker warnings and enabling warnings as errors (#6006) 2020-08-17 13:13:45 -07:00
Clint Rutkas
e671c913ab
Removind depercated fields (#6008) 2020-08-17 13:13:11 -07:00
Clint Rutkas
9d46fae865
Enabling warnings as errors and correcting StyleCop issues (#6007) 2020-08-17 13:11:59 -07:00
Clint Rutkas
315caaba1c
[WarningsAsErrors] Getting Most online (#6005)
* Enabling errors as warnings.

* removing plugin since it throws an error for release mode,  WIll fix in other release
2020-08-17 13:11:40 -07:00
Nkateko
7af4ffe341
[Settings] Migrate File Explorer Preview Settings (#5785)
* added MSTest project

* migrate file explorer preview settings

* updated test file

* fixed build
2020-08-17 13:10:56 -07:00
Enrico Giordani
8bf730baae
Remove 'AnyCPU' build configuration (#5999) 2020-08-17 20:17:16 +02:00
Clint Rutkas
d055ba1c3b
whitespace forced changes (#6002) 2020-08-17 10:00:56 -07:00
Aaron Junker
649e7e103d
Update de.xaml (#5227)
* Update de.xaml

* Update de.xaml
2020-08-17 09:25:10 -07:00
Seraphima Zykova
947bf10c2f
Warning fix: calling convention of '__cdecl ' ignored; '__clrcall ' used instead (#5931) 2020-08-17 16:41:11 +03:00
Roy
55dc5dc19d
[Powertoys Run] Implemented "hidden files" flag in native Windows Search (#5500)
* Implemented "hidden files" flag in native Windows Search

* add missing file

* Change InitQueryHelper back to static

* Fix Line Endings

* Add files via github

Co-authored-by: Roy <royvou@hotmailcom>
2020-08-15 14:11:56 -07:00
martinchrzan
04c80915e5
Trying to dispose mouse hook earlier to potentialy fix the lagging mouse bug after selecting the color (#5530) 2020-08-15 17:28:53 +02:00
Clint Rutkas
be36b4aac1
correctin file ending (#5970) 2020-08-14 15:10:06 -07:00
Nkateko
2ce16bcdb7
[Settings] Migrate PowerRename Tests (#5787)
* added MSTest project

* migrated powerrename tests

* updated test

* reverted changes to xaml file
2020-08-14 14:26:41 -07:00
Nkateko
1683f191a9
[Settings] Migrate Shortcut Guide Settings Tests (#5789)
* added MSTest project

* migrated shortcut guide tests

* updated tests

* updated tests

* reverted changes to xaml file
2020-08-14 13:58:48 -07:00
Clint Rutkas
70d93a0bfc
C26819 - Directly stating this fallthrough is correct (#5967)
* Directly stating this fallthrough is correct

* Update MockedInput.cpp

Adjust per Arjun
2020-08-14 13:35:58 -07:00
Clint Rutkas
6514712054
[stylecop] Launcher (#5968)
* Should be last stylecop change!

* two more tweaks
2020-08-14 13:35:06 -07:00
Clint Rutkas
e0a1b478a1
Program plugin fully on stylecop (#5964) 2020-08-14 12:46:23 -07:00
Clint Rutkas
be5d58c849
incorrect override of SA1401 (#5965) 2020-08-14 12:41:55 -07:00
Clint Rutkas
e4f9c02d11
Lots of small tweaks (#5960) 2020-08-14 11:50:14 -07:00
Clint Rutkas
5c1713f274
wrapping up everything minus var renaming (#5952) 2020-08-14 09:22:24 -07:00
Clint Rutkas
913615f1c2
more braces and whitespace style errors (#5951) 2020-08-14 09:22:12 -07:00
Arjun Balgovind
9e8b0d2807
Refactored Keyboard Manager UI code and added unit tests for Keyboard Manager UI (#5718)
* Added tests for loading and saving remappings in the UI

* Added tests for ApplyRemappings methods

* Moved single key remap validation logic to separate method so that it can be tested

* Added tests for single key remap validation in UI

* Refactored shortcut validation code to be testable

* Added some shortcut validation tests

* Refactored code to be cleaner

* Added tests for action key and modifier key selection and formatted file

* Added tests for selecting None

* Added tests for selecting Null

* Added tests for WinL error

* Added CtrlAltDel tests

* Added tests for MapToSameKey

* Added tests for mapping repeated shortcut

* Fixed const correctness

* Clean up type names with type alias

* Clean up ValidateAndUpdateKeyBufferElement tests and tweak ValidateShortcutBufferElement signature

* Fixed bug when None selected

* Refactored one test as per test case framework

* Cleaned up more tests

* Cleaned up buffer validation tests

* Added tests for KBM Common Helpers and Shortcut
2020-08-13 16:32:15 -07:00
Nkateko
0b5749d491
[Settings] Migrate Color Picker Settings Tests (#5759)
* added MSTest project

* migrated color picker settings

* undo changes for the .xaml page
2020-08-13 15:46:51 -07:00
Clint Rutkas
23a9fa40e7
Additional formatting tweaks (#5909) 2020-08-13 15:32:12 -07:00
Clint Rutkas
38b0d427f8
Fix all file naming tweaks (#5945) 2020-08-13 15:31:32 -07:00
Clint Rutkas
e02977edc0
Whitespace and type fixes (#5917) 2020-08-13 15:31:14 -07:00
Nkateko
24d7232559
[Settings Tests] Migrate General Settings tests (#5753)
* added MSTest project

* migrated general settings tests

* enabled settings tests run in the build pipeline

* added tests

* move relay command class to separate file

* added a foldername parameter for general settings view model
2020-08-13 15:02:05 -07:00
Clint Rutkas
e4ea8d2abd
Correcting floating point error (#5949) 2020-08-13 14:02:38 -07:00
Nkateko
ebd1a6406b
[Settings] Unit Tests Migration Feature Branch Merge (#5754)
* added MSTest project

* enabled settings tests run in the build pipeline

* re-added settings test project

* re-added test project and sample test

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* updated settings test output path

* updated output path for release config

* added xunit test project

* removed xunit test project

* fix build

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-ci.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-ci.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml

* Update build-powertoys-steps.yml
2020-08-13 13:51:01 -07:00
Clint Rutkas
5079ee67c3
[stylecop] program plugin unit tests part2 (#5925)
* Another batch

* Commenting out stylecop
2020-08-13 11:10:55 -07:00
Seraphima Zykova
9592fab414
Warning fix: removed additional dependencies in common project (#5930) 2020-08-13 15:25:36 +03:00
Enrico Giordani
f36858d074
update readme for WinAppDriver tests (#5927) 2020-08-13 13:08:36 +02:00
Seraphima Zykova
1b8bb7c445
Warning fix: Variable is uninitialized. Always initialize a member variable (#5928) 2020-08-13 13:48:15 +03:00
Divyansh Srivastava
f499ff81f2
Prevent copying of files from folder to shell plugin (#5893) 2020-08-12 15:16:29 -07:00
Alekhya
e80c7b6b45
Fix for PowerLauncher crash - Type Load Exception (#5906)
* Added the version number for all launcher projects so that they are in sync with the powerToys version number

* Removed internals visible to Wox.dll as we no longer have that library
2020-08-12 14:18:01 -07:00
Arjun Balgovind
f3babcb46e
Fixed exceptions in indexer and delayed execution logic (#5912) 2020-08-12 12:44:55 -07:00
Clint Rutkas
95e82ca359
[stylecop] program plugin/unit test first pass (#5908)
* initial pass

* multiple whitespace fixes
2020-08-12 11:46:11 -07:00
Clint Rutkas
8888739867
fixing all warnings and info for infra (#5891) 2020-08-12 10:44:58 -07:00
ryanbodrug-microsoft
db6e9b6962
Adding FxCop to Program Plugin Unit Tests (#5884)
* Adding FxCop to Microsoft.Plugin.Program.UnitTests

* CA1707: Identifiers should not contain underscores
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1707?view=vs-2019

* CA1307: Specify StringComparison
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1307?view=vs-2019

* CA1812: Avoid uninstantiated internal classes
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1812?view=vs-2019

* More CA1707: Identifiers should not contain underscores fixes now that class is public

* More fixes for https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1812?view=vs-2019

List Repository and Win32ProgramRepository

* More CA1707: Identifiers should not contain underscores fixes now that class is public

ListRepository and Win32ProgramRepository tests

* Adding `ConfigureAwait(false)` and removing Assert.DoesNotThrowAsync as thowing an exception will fail the test anyway, and the DoesNotThrowAsync method can't be awaited.

Fix for CA2007: Do not directly await a Task (Consider calling ConfigureAwait on the task).

CS1998 This async method lacks 'await' operators and will run synchronously. Consider using the 'await' operator to await non-blocking API calls, or 'await Task.Run(...)' to do CPU-bound work on a background thread.

* Setting treat warning as errors to true for release and debug.
2020-08-12 10:03:34 -07:00
Clint Rutkas
a0832d3fb6
enabling stylecop (#5885) 2020-08-11 16:35:58 -07:00
Divyansh Srivastava
1c77887629
Reduce folder plugin results (#5631)
* Reduce folder plugin results

* Added warning message

* Added UI content for warning message in folder plugin

* nit fixes for folder plugin changes

* Localised warning message

* fix Merge conflicts

* nit fixes and move warning to end of results

* Add IDisposable interface to folder plugin

* Add images to MSI
2020-08-11 15:06:40 -07:00
Arjun Balgovind
dcd0ca8daa
[PT Run] Split indexer plugin's queries into a fast and slow query (#5748)
* Added regex code

* Added regex based method to remove all LIKE queries

* Made regex readonly

* Added plugin interface and code to execute slower plugins after the fast plugins

* Added scoring for indexer and added statement to remove old indexer results

* Refactored from master and added thread sleep for debugging

* Removed lock from indexer plugin and added checks to avoid exceptions

* Remove debug statement

* Removed selected index update and fixed tests not building

* Added tests

* Removed scoring

* Removed lock

* Resolve merge conflicts

* Moved dispatcher code to function and add parallel foreach loop

* Removed DelayedExec metadata and modified QueryForPlugin to run only delayed exec plugins when bool param is true

* Removed metadata from plugin.json
2020-08-11 14:52:03 -07:00
Clint Rutkas
304981fcf2
[stylecop] Wox.Core - last amount needed to fully integrate (#5877)
* Looks like it was done

* StyleCop enabled for WoxCore
2020-08-11 14:12:08 -07:00
Clint Rutkas
f1bb533321
[StyleCop] Wox.Plugin - last amount needed to fully integrate (#5853)
* StyleCop for Plugin

* getting release mode working
2020-08-11 13:41:41 -07:00
Clint Rutkas
2c49df4be3
more fixes for getting styleCop up, this will need one more push to get another 15 that will require renaming of vars (#5875) 2020-08-11 13:40:26 -07:00
Roy
90502f7553
Add Microsoft.Plugin.Uri.UnitTests to CI + Fix Tests (#5878)
Co-authored-by: Roy <royvou@hotmailcom>
2020-08-11 11:49:44 -07:00
Mehmet Murat Akburak
18f5c7f691
[PowerRename] Use the same label size for all options (#5870) 2020-08-11 21:31:16 +03:00
Divyansh Srivastava
2d2cb22806
Stable sorting of ResultCollection (#5850)
* Stable sorting of ResultCollection

* nit fixes for resultsViewModel and ResultCollection
2020-08-11 10:24:56 -07:00
ryanbodrug-microsoft
ac10c988b9
Enable Static Analysis on programs plugin (#5847)
* Removing unused ProgramSettings constructor paramaters.

* Fix for:

Severity Code Description Project File Line Suppression State
Error CA1829 Use the "Count" property instead of Enumerable.Count(). Microsoft.Plugin.Program C:\Repos\PowerToys\src\modules\launcher\Plugins\Microsoft.Plugin.Program\Views\ProgramSetting.xaml.cs 182 Active

Severity Code Description Project File Line Suppression State
Error CA1827 Count() is used where Any() could be used instead to improve performance. Microsoft.Plugin.Program C:\Repos\PowerToys\src\modules\launcher\Plugins\Microsoft.Plugin.Program\Views\ProgramSetting.xaml.cs 287 Active

* Fixes for CA1031:
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1031?view=vs-2019

* More fixes(Suppression) for CA1031 (Catching base exception)
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1031?view=vs-2019

* Fix for nested types being externally visible.  CA1034
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1034?view=vs-2019

* Fix for  CA1028 If possible, make the underlying type of Hresult System.Int32 instead of uint. Microsoft.Plugin.Program C:\Repos\PowerToys\src\modules\launcher\Plugins\Microsoft.Plugin.Program\Programs\UWP.cs 236 Active

* Fix for CA2227 Collection properties should be readonly.
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2227?view=vs-2019

Fix rror CA2211 Non-constant fields should not be visible
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2211?view=vs-2019

* CA2208: Instantiate argument exceptions correctly
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2208?view=vs-2019

* Win32.cs Static analysis fixes:

CA2200: Rethrow to preserve stack details
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2200?view=vs-2019

CA1825: Avoid zero-length array allocations
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1825?view=vs-2019

CA2211: Non-constant fields should not be visible
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2211?view=vs-2019

* More Win32.cs static analysis fixes:

CA1307: Specify StringComparison
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1307?view=vs-2019

Verifying query is not null before using it.
CA1062: Validate arguments of public methods
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1062?view=vs-2019

CA1305: Specify IFormatProvider
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1305?view=vs-2019

* UWPApplication.

CA2007: Do not directly await a Task
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca2007?view=vs-2019

* Error CA2010 Consume the hresult returned by method 'Microsoft.Plugin.Program.Programs.AppxPackageHelper.IAppxManifestApplication.GetStringValue(string, out string)' and call Marshal.ThrowExceptionForHR.

Note:  CA2010 has been removed from future FXCop versions as it can provide incorrect advice for methods that don't return hresult (possibly when [PreserveSig] has been incorrectly labeled.)  I've verified the methods in question do still return hresults.

* More fixes for
Error CA2010 Consume the hresult returned by method and call Marshal.ThrowExceptionForHR.

* Fixes for:
Error CA2000 Call System.IDisposable.Dispose on object created before all references to it are out of scope.

* Suppress CA1031:Do not catch general exception types

* Fixes for
Error CA1034 Do not nest type ...

* Fixing Unit tests that were broken as per a previous fix.

* Fix for: CA1034: Nested types should not be visible:
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1034?view=vs-2019

* Suppressing CA1707 for native/com types.
CA1707:Identifiers should not contain underscores

* Fix for Error CA1307 The behavior of 'string.Replace(string, string?)' could vary based on the current user's locale settings.

* Fixes for Error CA1825 Avoid unnecessary zero-length array allocations.  Use Array.Empty<string>() instead.

* Fix for: Error CA1823 Unused field 'IndexLock'.

* Fixes for CA1822: Mark members as static:
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1822?view=vs-2019

* Fix for Error CA1819 Properties should not return arrays

* Fix for Error CA1806 ContextMenus calls Trim but does not use the new string instance that the method returns. Pass the instance as an argument to another method, assign the instance to a variable, or remove the call if it is unnecessary.

* Fix for Error CA1801 Parameter settings of method UpdateSettings is never used. Remove the parameter or use it in the method body.

* Fix for Error CA1724 The type name Settings conflicts in whole or in part with the namespace name 'Microsoft.PowerToys.Settings'.

* Includes FxCop for static analysis

* Fix for Error CA1717 Only FlagsAttribute enums should have plural names

* Suppress Stgm flags: Error CA1714 Flags enums should have plural names Microsoft.Plugin.Program

* Rename Win32 to Win32Program

Fix for: Error CA1724 The type name Win32 conflicts in whole or in part with the namespace name 'Microsoft.Win32' defined in the .NET Framework. Rename the type to eliminate the conflict.

* Fixes for Error CA1507 Use nameof in place of string literal

* Using ordinal instead of invariant culture when not symbolic comparison

* CA1308: Normalize strings to uppercase
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1308?view=vs-2019

* CA1304: Specify CultureInfo
CA1305: Specify IFormatProvider

https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1305?view=vs-2019
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1304?view=vs-2019

* CA1062: Validate arguments of public methods
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1062?view=vs-2019

* CA1056: URI properties should not be strings
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1056?view=vs-2019

Fix:   Making LogoURi private, as it is only used internally and operated on as a string

* Warning CA1052 Type 'AppxPackageHelper' is a static holder type but is neither static nor NotInheritable

* CA1060: Move P/Invokes to NativeMethods class
https://docs.microsoft.com/en-us/visualstudio/code-quality/ca1060?view=vs-2019

* Programs Plugin - Treat warnings as errors true

* CA1031:Do not catch general exception types
Missed release only compile issue.  Making debug and release behave the same.

* Renaming 'Create' to 'CreateWin32Program' based on PR feedback.
2020-08-11 09:08:44 -07:00
Ivan Stošić
83de1686c0
Don't wait for ColorPicker.exe to close (#5866) 2020-08-11 17:06:28 +02:00
vldmr11080
145347f7ae
[FancyZones] Clasify strings in FancyZones to localizable and non-localizable (#5315)
* Clasify strings in FancyZones to localizable and non-localizable

* Address PR comments

* Better handling of FirePropertyChanged event

* Address PR comments

* Update properties
2020-08-11 13:51:06 +02:00
Ivan Stošić
b8b6dbe791
Potential fix for a crash in OnThreadExecutor (#5840) 2020-08-11 10:39:18 +02:00
Divyansh Srivastava
d21201e996
Reduce program plugin results (#5743)
* Added minimum score threshold

* nit fix for program plugin
2020-08-10 16:25:34 -07:00
Roy
ba2ef23414
[PowerToys Run] Add Support for Uris (#5160)
* url handler plugin

* updates

* Add seperate interface classes
rename to uri module

* Update path

* Update implementation to remove slow DNS lookup ( and let browser handle it)

* tabs to spaces

* - Update icon/assets
- Finalize Project

* Update wix project

* Implement UpdateBrowserIconPath

* Implemented Microsoft.CodeAnalysis.FxCopAnalyzers

* Add Language component to installer

* Update logic to determine icon

* Update Translation File to "Open in browser"

* Added test for typing http://test.com and which result to expect on each keystoke

* Implement StyleCop

* Added ipv6 tests

* Fix Solution LineBreaks

* Added Microsoft.Plugin.Uri as build Dependency

* Use ArgumentNullException instead of InvalidOperationException

* Fix wrong Directory in wix installer

Co-authored-by: Roy <royvou@hotmailcom>
2020-08-10 15:53:43 -07:00
Divyansh Srivastava
3781d1e06b
Consolidate folder and shell plugin (#5843)
* Added folder plugin functionality to shell plugin

* Added QueryTextDisplay for shell plugin

* Remove QueryTextDisplay change

* Fix merge conflict issues
2020-08-10 15:51:02 -07:00
Clint Rutkas
082a78bd92
Getting remaining Tests on stylecop (#5846) 2020-08-10 15:49:36 -07:00
Clint Rutkas
7bfd0823db
Enabling StyleCop for folder plugin (#5844) 2020-08-10 13:28:22 -07:00
Enrico Giordani
013ffe1626
Now working on 0.20.2 (#5834) 2020-08-10 16:30:25 +02:00
Divyansh Srivastava
b2006f2466
Remove all plugin results on query change (#5796) 2020-08-07 19:27:52 -07:00
Niels Laute
7d8931696d
Localized Image resizer tooltip (#5529)
Co-authored-by: Niels Laute <niels9001@hotmail.com>
2020-08-07 17:54:56 -07:00
Niels Laute
e88812458e
[Settings] Updated adaptive trigger behavior (#5434)
* Updated adaptive trigger behavior

* Fixed wrapping for KBM subtitle textblock

* Fix

Co-authored-by: Niels Laute <niels9001@hotmail.com>
2020-08-07 12:00:48 -07:00
Clint Rutkas
ada42f6e94
in theory this fixes all SA1649 issues now with any project with stylecop enabled (#5786) 2020-08-07 11:56:28 -07:00
Clint Rutkas
34c3b50b48
Incremental fix for StyleCop on Infra (#5729)
* Fixes file names and classes don't match.  All but PluginsSettings

* making it pluginsettings

* fixing due to conflict
2020-08-07 10:45:50 -07:00
Andrey Nekrasov
63c36d0dbf
runner: don't try to restart explorer (#5763) 2020-08-07 15:26:34 +03:00
Andrey Nekrasov
bd80bb6bb3
bootstrapper: add support for silent arg (#5590) 2020-08-07 12:00:14 +03:00
Ivan Stošić
8f98866d71
[FancyZones] Feature to create zone layouts spanning multiple monitors (#5289)
* Added the setting

* Added a property to Editor Settings

This will be used later

* Fixed a bug in the previous commit

* Simplified a method

* Added snapping points to the editor

* Simplified a method in ZoneSet

* Updated ZoneSet testcases

* Add a method to FancyZones / ZoneWindowHost

* Almost works

* The editor now launches, but FZ does not understand the results

* Refactored some code

* Snapping to a zone by dragging seems to work

* Hotkeys seem to work

* Refresh the work area handler after changing settings

* Fixed zones not snapping to monitor edges when moved

* Remove unused method in FancyZones.h

* Fixed an issue with DPI awareness

* Renamed setting to spanZonesAcrossMonitors

* Renamed a function

* Fixed a bug with the magnetic effect

* Fix restoring window positions on layout changes
2020-08-07 10:06:25 +02:00
Clint Rutkas
26bf05dd7e
whitespace changes (#5750) 2020-08-06 20:38:49 -07:00
Clint Rutkas
b815718c26
whitespace only (#5747) 2020-08-06 16:52:25 -07:00
Clint Rutkas
d7994ca67d
style cop wox.core whitespace changes (#5744)
* whitespace changes

* undoing csproj tweak to keep stylecop off
2020-08-06 16:51:47 -07:00
Arjun Balgovind
b95a1fb604
Unlinked the MaxResults value from settings and set to fixed value of 30 (#5742) 2020-08-06 16:44:13 -07:00
martinchrzan
b04bb2ef8d
Color picker respects right monitor side boundaries and does not go outside of the view (#5480) 2020-08-06 20:54:26 +02:00
martinchrzan
066aeec1e6
Fixed jerky zoom animation (#5483) 2020-08-06 20:53:16 +02:00
Clint Rutkas
d6e46d73b5
whitespace stylecop fixes for Wox.Infra (#5689)
* Limited to whitespace

* removing stylecop again
2020-08-06 11:28:13 -07:00
Clint Rutkas
7b767df0b5
getting stylecop undercontrol for UI warnings (#5630) 2020-08-06 11:16:25 -07:00
Clint Rutkas
ed36447bdf
Fixing stylecop violations (#5629) 2020-08-06 10:10:44 -07:00
Clint Rutkas
0f90af3c7d
URL audit (#5685) 2020-08-06 10:09:50 -07:00
stefansjfw
f50a8e5252
Fix difference in editor and applied focus layout zones size and increments (#5601) 2020-08-06 16:41:15 +02:00
vldmr11080
1d8ca28152
Don't restore minimized windows after layout is updated (#5603) 2020-08-06 16:22:47 +02:00
vldmr11080
6c4129d02a
[FancyZones] Do not restore maximized windows (#5597)
* Do not restore maximized windows

* Fix show command comparison

* Move maximized check outside of RestoreWindowSize function
2020-08-06 15:12:49 +02:00
Nkateko
4543b32bef
fix settings path (#5692)
* fix settings path

* Update settings_window.cpp

* rollback commit #5487
2020-08-06 00:49:40 -07:00
Clint Rutkas
ff69f6ed7f
fixing most whitespace issues, reordering namespaces and adding in headers (#5677) 2020-08-05 14:06:55 -07:00
Clint Rutkas
92a2b83bc8
smaller stylecop fixes in Wox.Core and Wox.Infra (#5671)
* Headers
unneeded usings
files need blank line at bottom
Fixed double returns
Returns after braces

* commenting out stylecop
2020-08-05 14:06:42 -07:00
Alekhya
30b65028fe
Fix Code Related PT Run Accessibility issues (#5610)
* set the name automation properties for the result elements

* Added name properties to search box

* removed the name for the grid

* localized the automation property names of the launcher control

* Localized the automation name property for the result list

* Uncommented out the Hide() function which was commented out to run Accessibility Insights

* modified resources from static to dynamic

* reverted access modifier to internal as we are no longer using this

* updated csproj file
2020-08-05 13:43:47 -07:00
Andrey Nekrasov
59ebe30b72
runner: initialize COM security, so toast notifications work in elevated context from non-admin account (#5314) 2020-08-05 19:06:50 +03:00
Alekhya
814f6213fa
Added null check before using unregister hotkey function (#5627) 2020-08-05 08:06:03 -07:00
Andrey Nekrasov
dce3ee440b
bootstrapper: use a dedicated solution (#5318) 2020-08-05 17:20:50 +03:00
Clint Rutkas
b87d14cd61
Proper fix for MSB3052. (#5618)
* fixing MSB3052

* adding back in to unblock build

* More agressive refactor.  Moved the define constant to wixproj and actual version into src file version prop

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-08-05 00:04:18 -07:00
Arjun Balgovind
5c10c78595
Fixed exceptions in dispose not allowing PT Run to terminate (#5615) 2020-08-04 21:06:07 -07:00
Clint Rutkas
a793cf4ac2
onboarding stylecop (#5622) 2020-08-04 16:39:25 -07:00
Roy
010732108c
Add "AssemblyTitle" attribute which is used for the taskbar menu name. (#5487)
Co-authored-by: Roy <royvou@hotmailcom>
2020-08-04 16:36:59 -07:00
Clint Rutkas
296d103f68
Getting Shell on stylecop (#5620) 2020-08-04 16:27:35 -07:00
Clint Rutkas
1f590c45be
Unit tests getting up-to-par for StyleCop (#5364)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-08-04 14:01:37 -07:00
Hector Minaya
d11b5b3e02
Power Launcher | #5062 Moved Start Typing... to resource file (#5408) 2020-08-04 09:53:58 -07:00
Ivan Stošić
8f8787b2e0
Fixed Launcher not exiting when PT is terminated (#5588)
* Fixed Launcher not exiting when PT is terminated

* Added a null check to _hotkeyManager as well
2020-08-04 14:33:07 +02:00
Andrey Nekrasov
7581802498
Fix bootstrapper getting stuck on "installing dotnet" (#5565) 2020-08-04 13:34:09 +03:00
Andrey Nekrasov
371523d756
notifications: provide default app id to fix FZ toast crashes (#5551) 2020-08-04 11:12:49 +03:00
Clint Rutkas
1456be9feb
wrapping agressively the timer. (#5560)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-08-03 16:46:15 -07:00
martinchrzan
62f57b134a
Fixing potentially infinite loop with logs in Color Picker (#5558) 2020-08-03 22:03:00 +02:00
Hector Minaya
8fc3f1ccbd
[Fancy Zones] Add scrollbar to the input field for excluded apps in the settings page (#5410) 2020-08-01 07:48:38 +02:00
Clint Rutkas
c946f10d0c
fixing all warnings and i think i got one larger one that was before stylecop was enabled, OnOpenWindowsUpdate (#5382)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-31 16:42:24 -07:00
Clint Rutkas
e03ef0b739
Remove InputSimulator nuget package (#5388)
* getting app to not use it, now installer

* removed windowinput.dll from inputsimulator nuget package

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-31 15:16:49 -07:00
Clint Rutkas
55b92ab263
supressing warning 8305 as there is nothing we can do about as this is a WinUI (#5393)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-31 15:15:50 -07:00
Divyansh Srivastava
fbc625478b
Improve query cancellation and ResultCollection performance (#5370)
* Added cancellation token to downstream functions in query thread

* Remove initial lag in query

* Re add query delay

* Remove debug flag
2020-07-31 15:09:23 -07:00
ryanbodrug-microsoft
4da8aab44f
Including valid package information when path is invalid. This is needed because the path will be invalid when uninstalling an application, but we still need the other information to remove it from the currently indexed list of uwp/packaged applications. (#5373) 2020-07-31 12:33:05 -07:00
Clint Rutkas
d9fd967c48
Style cop up and running (#5340)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-31 09:49:42 -07:00
Clint Rutkas
ab86fc9a5e
enabling stylecop on ColorPicker (#5336)
* Getting all warnings fixed

* fixed feedback, missed resize for some reason as well.

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-31 09:13:05 -07:00
martinchrzan
2fe84b7510
Fixed an issue of not being able to change settings for ColorPicker (#5351) 2020-07-31 16:10:08 +02:00
Andrey Nekrasov
46ef13dd0f
autoupdate: set app_id in time for download_update to use it (#5346) 2020-07-31 14:22:05 +03:00
Andrey Nekrasov
49b56d9b52
PowerToys interface: remove powertoys events and system_menu_helper functionality (#5323) 2020-07-31 14:06:13 +03:00
Clint Rutkas
7abb4072b5
getting stylecop added and online SvgThumbnailProviderUnitTests (#5335)
* getting stylecop added and online

* shifting out of csproj and into packages.config

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 17:36:39 -07:00
Clint Rutkas
d91fd0027a
stylecop online (#5341)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 17:31:41 -07:00
ryanbodrug-microsoft
8f17f7297d
Enabling static analysis on indexer plugin and fixing errors (#5220)
* Enabling code analysis, and treating warnings as errors

* Error CA1724 The type name Settings conflicts in whole or in part with the namespace name 'Microsoft.PowerToys.Settings'. Change either name to eliminate the conflict. Microsoft.Plugin.Indexer C:\repos\powertoys\src\modules\launcher\Plugins\Microsoft.Plugin.Indexer\Settings.cs 9 Active

* Removing keyword "Interface" from namespace to fix fxcop warnings

* Fixing static analysis warnings on ContextMenuLoader

* Fixing general exception warnings for static analysis

* Fixing public list variables, non static methods, and general exception warning

* Implementing IDisposable on OleDBSearch although in practice these objects were already being disposed.

Also Validated we were not using user input directly for sql strings.

* Removing VS generated comments from dispose methods as per PR feedback.

* Setting translated text to use current culture as per PR feedback.

* Explicity specifying 'internal' access modifier for Indexer 'Main' class, as per PR feedback

* Updating to FxCop 3.0.0
2020-07-30 16:39:47 -07:00
Clint Rutkas
aa8c31e79b
adding in global supressions (#5337)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 16:23:58 -07:00
Clint Rutkas
cfc768caa9
StyleCop rules enforced (#5339)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 16:23:20 -07:00
ryanbodrug-microsoft
c48bd9b840
User/ryanbod/fix unittests (#5191)
* Fixing PowerLauncherViewModelTest.cs.  These OpenConsole functionality was accidentlly removed in a merge conflict, which broke the build.  The build was fixed, but the unit tests didn't work.  034079b441 is the offending change.

* Color picker tests need to remove the ShellPage.DefaultSndMSGCallback on cleanup.

* Fixing casing that was updated in previous change.
2020-07-30 15:58:01 -07:00
Clint Rutkas
c09919055a
StyleCop for SvgThumbnailProvider (#5338)
* adding in global supression

* caught one more, stylecop was included vs linked

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 15:57:10 -07:00
Clint Rutkas
d35f1ea802
last nuget packages and fixed small errors (#5334)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 14:01:02 -07:00
dependabot[bot]
cfbf3cd4b3
Bump elliptic from 6.5.0 to 6.5.3 in /src/settings-web (#5302)
Bumps [elliptic](https://github.com/indutny/elliptic) from 6.5.0 to 6.5.3.
- [Release notes](https://github.com/indutny/elliptic/releases)
- [Commits](https://github.com/indutny/elliptic/compare/v6.5.0...v6.5.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-30 12:36:53 -07:00
Clint Rutkas
a46103fc8c
Adjusting interop tests for 5295 (#5296)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 12:22:33 -07:00
Clint Rutkas
d032956124
adding in stylecop goodness (#5301)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 12:17:08 -07:00
Clint Rutkas
ff93b38d23
upgrading all .NET assemblies, #5303 took care of ones where they needed consolidating (#5304)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 12:16:32 -07:00
Clint Rutkas
5b02ee5169
updated to Microsoft.Windows.CppWinRT.2.0.200729.8 (#5306)
* updated to Microsoft.Windows.CppWinRT.2.0.200729.8

* actually adding in packages.config and updating

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 11:37:15 -07:00
Clint Rutkas
aa770689f5
pointing toward linked global (#5297)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-30 11:37:00 -07:00
Andrey Nekrasov
de67fff731
autoupdate: handle exceptions in download_update (#5324) 2020-07-30 18:32:50 +03:00
Anish Asrani
7799783c9a
Updated Administrator mode URL to new wiki page (#5309)
* Updated URL to wiki page

* Updated URL to aka.ms link

Co-authored-by: Anish Asrani <anasrani@microsoft.com>
2020-07-30 07:11:07 -07:00
Andrey Nekrasov
52e9d37b93
chore: move codeAnalysis folder to src (#5311) 2020-07-30 11:59:24 +03:00
martinchrzan
f541e7105e
Generating AssemblyInfo.cs for ColorPicker.exe, added resources and version for ColorPicker.dll (#5299) 2020-07-29 14:45:41 -07:00
Andrey Nekrasov
4060e29c63
runner: make sure that explorer is restarted (#5293) 2020-07-29 12:58:15 -07:00
Niels Laute
d913285523
[Settings] Fix for theming aware titles (#5245)
* Fix for theming aware titles

* Converter fix
2020-07-29 11:38:03 -07:00
ryanbodrug-microsoft
d98d1193fc
Removing hardcoded version numbers from c# telemetry events. (#5283)
* Removing hardcoded version numbers from c# telemetry events.

* Removing dependency on powertoysInterop for getting version string.

* Defensive checks around getting assembly version
2020-07-29 11:18:21 -07:00
Enrico Giordani
e23b406364
Update version to 0.20.0 (#5288) 2020-07-29 13:19:57 +02:00
martinchrzan
0b27fc39e6
Added telemetry for Color Picker module (#5259)
* Added telemetry for Color Picker module

* Closing color picker with Esc and added a telemetry for that

* Missed update of csproj

* updated installer to include telemetry.dll for color picker

* removed telemetry.dll it was alrady there

* after review changes
2020-07-29 09:01:04 +02:00
Niels Laute
8fb446ad47
[Settings] Embed images (#5236)
* Added local images

* Margin fix

* Update Product.wxs

Added images to installer
2020-07-28 15:02:09 -07:00
Andrey Nekrasov
47cb34d26b
chore: enable multiprocessor compilation (#5272) 2020-07-28 17:20:01 +03:00
Andrey Nekrasov
8354797406
CDPx: do not use span header (#5268) 2020-07-28 14:26:30 +03:00
Divyansh Srivastava
87ae1c6a9b
Improving UI performance (#5216)
* Added fast observable collection

* Updated to use 1 collection changed event per query

* Moved result updating to background thread

* Changed collapsed to hidden for virtualization

* Moved all token cancellations inside try catch

* Fixed freeze on deleting first letter

* nit fixes

* Moved update logic to plugin result loop

* Updated doc comment for AddResults function

* fix result clear on empty query
2020-07-27 18:13:47 -07:00
Niels Laute
ba7302a197
[Settings] Adding collapse button to settings navview (#5237)
* Adding collapse button to settings navview

* Custom panewidth
2020-07-27 09:57:28 -07:00
stefansjfw
d15b0a0285
[FancyZonesEditor] Don't load malformed custom layout and show appropriate message (#5248)
* Introduce const strings in LayoutModel.cs

* Don't load malformed custom layout and show apropriate message

* Add more checks

* Address PR comments

* Address PR comments
2020-07-27 18:56:26 +02:00
Andrey Nekrasov
3796a5ef97
Autoupdate: implement updating bootstrapper utility (#5204) 2020-07-27 19:53:29 +03:00
stefansjfw
61669a73d9
[FancyZonesEditor] Introduce const strings in LayoutModel.cs (#5196)
* Introduce const strings in LayoutModel.cs

* Address PR comments - Update FirePropertyChanged
2020-07-27 10:12:35 +02:00
martinchrzan
5a2385c66b
Set default shortcut for activating launcher, creating settings.json … (#5206)
* Set default shortcut for activating launcher, creating settings.json on a start if it does not exists

* After review fixes
2020-07-25 08:50:29 +02:00
Alekhya
d7721065dc
Add theme aware default icons to usage dictionary (#5223)
* Added theme aware default icons to usage dictionary

* they should not be removed while resizing
2020-07-24 18:23:33 -07:00
Alekhya
025f2507f4
Drive Detection Indexer warning refinement (#5221)
* show results always and conditionally show warning

* changed test logic to show warning when expected

* renamed unit test
2020-07-24 17:45:07 -07:00
Alekhya
563fb3ff5c
commenting out the test (#5224) 2020-07-24 17:43:48 -07:00
Clint Rutkas
9646ec5edd
fixed another set of warnings (#5219)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-24 15:46:29 -07:00
Alekhya
cc990a1181
Fix for handling exceptions thrown by dispatcher which were crashing PT Run (#5199)
* fix report window error icon

* fix for launching web page to create new issue

* Made icon theme aware

* removed exception that was added by mistake

* modified the issue reporting link to match that in the settings page

* added comment
2020-07-24 13:58:40 -07:00
Arjun Balgovind
c4ddb7d351
[PT Run] Resolve text alignment issues for RTL input languages (not for mixed strings) (#5170)
* Added logic to switch TextBox/TextBlock flow direction on language change

* Move event handler to separate method

* Moved code to function
2020-07-24 13:34:49 -07:00
Arjun Balgovind
ab0047a9b7
Added additional checks in version info methods (#5173) 2020-07-24 13:34:17 -07:00
Arjun Balgovind
39ec10cbba
Add telemetry event for measuring time taken to display PT Run (#5201)
* Added LauncherHotkeyEvent

* Split into cold state and warm state events
2020-07-24 12:38:16 -07:00
Niels Laute
65b6513207
[Settings] Multiple UX refinements (e.g. OOBE) (#5113)
* Updated FZ page with new resizing logic

* Multiple UX fixes. Added updated resizing logic to other pages

* Added ImageResizer file format example snippets to tooltip

* Added warning icon in hotkeysettingscontrol

* Fixed formatting

* Keys label can now be set

* Replaced custom titleblocks with converter

* Updated strings

* Added correct links to the images. Added PT description on General page as well.

* Colorpicker image updates

* Rounded corners

* Fix

* Added back in correct subtitles
2020-07-24 12:02:56 -07:00
Clint Rutkas
beb4494534
Adding back in key for FZ Json (#5210)
* Adding back in key for FZ Json

* defaulting key to string empty

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-24 11:35:03 -07:00
martinchrzan
983ff901f2
Prevent clicking through when selecting a color using color picker (#5203) 2020-07-24 18:44:46 +02:00
Ivan Stošić
5d66473a4f
[FancyZones] Remove m_workArea from ZoneWindow (#5185)
* Removed m_workArea from ZoneWindow

* Remove another unused variable
2020-07-24 11:17:39 +02:00
Arjun Balgovind
ff1e04b957
[Keyboard Manager] Added in Shortcut to Key and Key to Shortcut remapping (#5070)
* Added union class

* Added key to shortcut backend implementation

* Added tests

* Added tests for CapsLock/modifier workaround for key to shortcut

* Added correct JSON loading step

* Cleaned shortcut remap code to use helper function for modifier keys

* Removed RemapKey class

* Enable Key to Shortcut in UI along with Type Shortcut in Remap key window

* Fixed orphaning and unsuccessful remap dialog

* Fixed column width

* Renamed second type key button

* Fixed Type Shortcut issues

* Fixed shortcut to key backend logic and manually tested most scenarios

* Added s2k in UI, manually verified its working

* Added one more k2s test

* Added tests for s2k

* Added tests for Caps Lock workaround in shortcut remaps

* Fixed formatting

* Fixed formatting

* Removed safety code since it can cause issues with code generated key up events

* Added test for key up scenario

* Tweaked warning text

* Tweaked text

* Tweaked text to fit in two lines

* telemetry additions
2020-07-23 16:43:49 -07:00
ryanbodrug-microsoft
53c4c6cbb8
User/ryanbod/folders enable staticanalysis (#5137)
* Enabling static analysis and settings treat warnings as errors

* Fixing/Supressing static analysis warnings in ContextmenuLoader and removing unused code

* Fixing static analysis errors in Main.cs

* Fixing static analysis warnings for folderpluginSettings.xaml.cs
2020-07-23 16:05:36 -07:00
Arjun Balgovind
47736603af
Fix saving to JSON in PT Settings (#5197)
* Added argument to fix saving to JSON in PT Settings

* Added argument to fix saving to JSON in PT Settings
2020-07-23 16:04:04 -07:00
Clint Rutkas
b6e5a5e655
Color picker tweaks (#5194)
* Adjustments on default keystroke and removing key string whihc really didn't do anything

* moving color picker into alphabetical order

* removing removed property

* adjusting comment based on feedback from martin

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-23 15:53:12 -07:00
Clint Rutkas
84018f5b61
Fixing more warnings (#5189)
* classes need to be in new files

* adding in new lines

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-23 14:56:21 -07:00
Clint Rutkas
592d3afe6d
shifting naming (#5190)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-23 13:08:20 -07:00
Clint Rutkas
2bd2ec7a2e
Renaming properties to C# styling to fix warnings (#5166)
* Renaming properties

* Update PowerLauncherProperties.cs

trying to kick CI

* PowerLauncher is way for naming.

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-23 11:01:49 -07:00
Alekhya
f25d2b3a86
removed incrementalClean for launcher (#5172) 2020-07-23 10:34:32 -07:00
ColdTune
c379cca2e5
[FancyZones Editor] Prevent new zones from being unreachable (#4457)
* stack new zones

* Changed startup location of window editor

* Zones start in upper left

* Changed Focus Zone Initialization

* Zones.Add

* Reset zone position when it goes off screen
2020-07-23 10:53:19 +02:00
Clint Rutkas
efa04b4cd8
Adding in headers (#5163)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-22 16:55:04 -07:00
Mehmet Murat Akburak
35a214603f
[PowerRename] Clear capturing groups with more than 1 digit (#5116)
User has actually signed CLA, see #4722

* Clear capturing groups with more than 1 digit

* Fix issue in regex pattern

* Add unittest

* Fix regex patterns

* Edit unittest

* Fix regex pattern, add some tests
2020-07-22 14:12:46 -07:00
Chris Davis
3acc96cab1
Check the shell attributes of the items to see if we should show the Power Rename menu item and or perform a rename. Also fix a unit test for the SVG Thumbnail Provider. (#5158) 2020-07-22 13:27:58 -07:00
Clint Rutkas
14247fa75a
Dev/crutkas/fixing warnings (#5161)
* new lines & braces

* Tabs /space auto fix

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-22 13:27:17 -07:00
Alekhya
6efec9d280
Minor text refinement in drive detection (#5132)
* minor text refinement

* removed the word Detected

* Revert "Merge branch 'tweakUIText_DriveDetectionWarning' of https://github.com/alekhyareddy28/PowerToys into tweakUIText_DriveDetectionWarning"

This reverts commit b193905d00, reversing
changes made to 0d0db138f8.

* Revert "Revert "Merge branch 'tweakUIText_DriveDetectionWarning' of https://github.com/alekhyareddy28/PowerToys into tweakUIText_DriveDetectionWarning""

This reverts commit b653814eec.

Co-authored-by: Clint Rutkas <clint@rutkas.com>
2020-07-22 13:10:53 -07:00
Arjun Balgovind
063253d5e7
Updated menu key name, and added missing IME key codes (#5110) 2020-07-22 12:57:13 -07:00
Divyansh Srivastava
f773604dec
Added functionality for left/right key navigation (#5067)
* Added functionality for left/right key navigation

* Update Behviour of left/right navigation

* Code cleanup

* Null check for results VM

* Added tests for results view model

* Update test namings
2020-07-22 12:48:42 -07:00
ryanbodrug-microsoft
25d43354b3
User/ryanbod/enable codeanalysis for calculatorplugin (#5130)
* Turning on static analysis and removing warning for NoMages.

* Fixing static analysis errors in NumberTranslator.cs

* Fix: Severity Code Description Project File Line Suppression State
Error CA1810 Initialize all static fields in 'Main' when those fields are declared and remove the explicit static constructor Microsoft.Plugin.Calculator C:\Repos\PowerToys\src\modules\launcher\Plugins\Microsoft.Plugin.Calculator\Main.cs 30 Active

* Throwing exception if arguments are null to fix static analysis errors.

* Ignoring CA1031

* Logging exceptions for Calculator queries.
2020-07-22 12:42:30 -07:00
Alekhya
b59ec5e78b
Fix for internet shortcut app not showing up on installation (#5131)
* added changed for internet shortcut app

* Added AppChanged event for url files

* Tests added

* refactoring
2020-07-22 10:58:01 -07:00
Clint Rutkas
1a210ae684
updating test related stuff (#5133)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-22 09:46:20 -07:00
Seraphima Zykova
92c666692d
[FancyZones] Dragging a window across monitors transparency fix (#5102) 2020-07-22 19:00:03 +03:00
stefansjfw
0027a0af40
[FancyZones] Split and reorganize FancyZonesData and JSON Helpers (#5028)
* Rename JsonHelpers to FancyZonesData
Add new JsonHelpers.[h|cpp] files

* Introduce FancyZonesDataTypes

* Move first part of JSON related stuff to JsonHelpers files

* Small refactor

* Move all json related stuff to JsonHelpers

* Minor refactoring

* Fix formating

* Remove GetPersistFancyZonesJSONPath() and GetPersistAppZoneHistoryFilePath()
Remove GetActiveZoneSetTmpPath(), GetDeletedCustomZoneSetsTmpPath and GetAppliedZoneSetTmpPath()
Simplify tests

* Address PR comment - Rename FancyZonesDataNS to FancyZonesData

* Address PR comment - Rename local var

* Delete obsolete stuff

* Remove double and uneeded includes
Introduce const non-localizable string variables
Address all othe PR comments

* Add comments to explain hardcoded values

* Remove FancyZonesData namespace

* Introduce const non-localizable string variables in FancyZonesDataTypes

* Add comments to explain FancyZonesData maps

Co-authored-by: Clint Rutkas <clint@rutkas.com>
2020-07-22 10:39:13 +02:00
Clint Rutkas
4f45cf1386
Upgrading CppWinRT and adding in new packages.config (#5134)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-22 00:35:39 -07:00
Clint Rutkas
9dfa685fb1
update WinUI and Xaml Islands (#5135)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-21 17:41:07 -07:00
Chris Davis
40d2ef4f0a
Add SVG Thumbnail Provider for Windows Explorer (#5048)
* Add SVG Thumbnail Provider

* Some cleanup

* Small settings changes

* Update PowerToys.sln

Remove Any CPU entries

* Fix project configuration issues

* Fix bad merge

* Update output path for SVG thumbnail provider

* Sync with latest
2020-07-21 16:27:12 -07:00
Clint Rutkas
398991f3c1
Adjusting settings to leverage base class (#5127)
* renaming / deleting file

* adding in base class

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-21 14:06:39 -07:00
Arjun Balgovind
d01b93ae5f
Move OS detection to common and PowerToysInterop (#5120)
* Remove os-detection project

* Removed os-detection project from sln

* Added os-detection to PowerToysInterop

* Removed references to os-detection and added PowerToysInterop.dll to the ImageResizer folder
2020-07-21 12:01:59 -07:00
Alekhya
b31d9761fa
Fix for the issue where PT Run was preventing UWP apps from building in VS (#5109)
* We should not deny other processes access to this item

* added a catch block for argument exception

* using memory stream instead of URI

* removed denyNone as it is the default config
2020-07-21 10:26:37 -07:00
Alekhya
96cd135f82
Detect if all Drives are indexed and show a warning if they aren't (#5015)
* opens new settings search options

* Catching file not found exception

* removed unnecessary header files

* Added display strings and cleaned up code

* reduced the number of max results to 30

* added log statement for exception

* Added drive detection to settings ui but still doesn't reflect on toggling it

* added getter setter for DriveDetectionWarning

* Got UI and backend to work as expected

* Reading value from registry working as expected

* Added test for settings

* Added tests for drive detection

* rename drive detection

* Localized indexer string

* formatting

* resolving merge conflict

* Added theme aware warning icon

* changed text for the warning

* Added the warning images to the installer
2020-07-20 17:50:42 -07:00
Divyansh Srivastava
c85cd4ac24
Migrate files from Wox to PowerLauncher (#5014)
* Moved all files from Wox to Powerlauncher

* Removed Wox project

* Changed namespace for imported files

* Resolved errors for VM

* Added build dependency order

* Fixed errors in helper class

* Remove Wox files

* Fixed errors in SingleInstance class

* Fixed wox.tests

* Fixed MSI

* Removed obsolete methods from PublicAPI

* nit fixes

* Throw null exception

* Fix merge conflict
2020-07-20 11:22:03 -07:00
vldmr11080
29e2c982d4
Handle desktop switch and open on active monitor functionality (#5065) 2020-07-20 11:55:19 +02:00
martinchrzan
bc301f269a
New color picker module - integrated from github.com/martinchrzan/Col… (#4778)
* New color picker module - integrated from github.com/martinchrzan/ColorPicker

* Trying to fix build in github

* Replaced icon in the settings to use font icon instead of path icon

* Closing ColorPicker.exe when PowerToys process closed, added color picker project into runner dependencies, restoring cursors on exit, added ManagedCommon as a dependency into installer

* User/ryanbod/fix colorpicker release (#5046)

* Changing configuration to x64 instead of AnyCPU.   The previous configuration was preventing the ManagedCommon binary from being loaded in Release.

* Updating MSI Installer with new icons (#4998)

* Adding missed dll into installer

* Fixed potential exception

* Creating settings.json on the first start when there are none, fixed default keyboard shortcut

* Added ColorPicker.exe.config into installer

* Start filewatcher after default settings file is created

* Fixing build

Co-authored-by: ryanbodrug-microsoft <56318517+ryanbodrug-microsoft@users.noreply.github.com>
2020-07-18 21:27:36 +02:00
Alekhya
d09253e532
Functionality to detect Win32 apps which are installed, deleted or renamed while PowerToys is running (#4960)
* Added file system wrapper and interface

* added win32program repository which would load store app and also handle new apps being added/deleted

* Added event handlers to win32 program repo

* added paths to monitor and setting FSWs for each location

* Events firing as expected

* filter extensions added, events fire as expected

* override gethashcode so that duplicates don't show up. OnCreated and OnDeleted events trigger as expected

* implemented setter for filters in FileSystemWatcher

* Rename adds item but does not seem to delete the previous app

* catching an exception when a duplicate item is inserted

* Removed notify filter for directory because we only need to monitor files

* Added exe programs to be indexed in the desktop and startmenu

* created a new class to init FileSystemHelpers instead of main

* Added fix for shortcut applications to work as expected while renaming and deleting them

* Added wrappers for file system operations

* Added some tests

* Added all tests for appref-ms and added a condition to search in sub directories

* Added tests for Exe applications

* Added lnk app tests

* Added tests for shortcut applications

* removed unnecessary wrappers

* override Equals for win32

* removed debug statements

* Fixed exe issue

* Fixed internet shortcut exception

* fixed renaming shortcut apps

* Added a retry block for ReadAllLines

* capitalized method name - RetrieveTargetPath

* made naming consistent, helper variables start with underscore

* Added the exception condition back

* renamed Win32ProgramRepositoryHelper to Win32ProgramFileSystemWatchers

* made win32Program repository variable static

* changed list to ilist

* disposed file system watchers

* make retrieveTargetPath upper case in tests
2020-07-17 22:32:21 -07:00
Nkateko
034079b441
fixed build failure (#5071)
Co-authored-by: Lavius Motileng <laviusntk>
2020-07-17 16:13:13 -07:00
Divyansh Srivastava
45bab578c4
Fix Focus issue on clicking list view (#5045)
* Focus working after right click

* Removed unnecessary focussable setter
2020-07-17 12:29:36 -07:00
Nkateko
e8de6f0ace
[Settings]Change text color for disabled controls (#4837)
* change text color for disabled controls

* added custom textblock controls and updated FZ Xaml

* updated Image Resizer Page

* updated Shotcut Guid

* updated KBM Settings

* reverted unrealted changes

* reverted unrealted changes

* reverted unrealted changes

* reverted unrealted changes

* updated power launcher

* reverted unrealted changes

* Image Resizer: renoved spaces in file format hint text

* Image Resizer: restored file format header

Co-authored-by: Lavius Motileng <laviusntk>
2020-07-17 11:01:46 -07:00
Andrey Nekrasov
13c2ce3f31
autoupdate: wait for the .exe updater to exit before restarting PowerToys (#5004) 2020-07-17 11:51:20 +03:00
Divyansh Srivastava
3bf9a3833a
Fix for result on empty query (#4927)
* Updated last query before clearing results

* Cancel last query expicitly
2020-07-16 16:23:01 -07:00
Enrico Giordani
c035bf2d37
Update version to 0.19.3 (#5033) 2020-07-16 17:15:05 +02:00
Mehmet Murat Akburak
a8153dd8db
[PowerRename] Using File Date Time Attributes Feature (#4722)
* Add basic using file attributes functionality

* Correctly return result

* Refactor

* Move retrieving date attribute to get function

* Cover various milliseconds patterns, retrieve file attributes only when needed

* Correctly check if date/time pattern is used. Remove wstring cast

* Use correct flags on CreateFile call to handle directories

* rebase to master

* Perform transform operation at last to make it not mess with date/time variables

* Refactor, remove extra space
2020-07-16 14:24:49 +03:00
dependabot[bot]
ebe70a52d1
Bump lodash from 4.17.15 to 4.17.19 in /src/settings-web (#5024)
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.15...4.17.19)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-07-16 12:19:58 +02:00
Seraphima Zykova
2282e72d03
[FZEditor] Grid layout resizers fixes (#4095)
* Swap resizers on drag
* Update resizers on split if existing split is used
* Fix accuracy error
* Zone ids are ordered
* Cancel merge on other actions
* Split if one of the snapped splitters is dragged
2020-07-16 12:54:15 +03:00
C. Augusto Proiete
5a590512bd
Rename MarkDown -> Markdown to resolve differences for non-Windows machines (#3758) 2020-07-15 10:23:59 -07:00
ryanbodrug-microsoft
6131181ea4
Updating MSI Installer with new icons (#4998) 2020-07-15 05:35:08 -07:00
Roy
78946c11ea
[PowerToys Run] Implemented Setting to Clear Search Query when PowerToys Run is Launched (#4995)
* Implemented Clear Input On Launch

* Move logic to seperate command on viewmodel

* Added Settings Sync
Moved logic from OnDeactivated to OnActivated

* Complete after testing

Co-authored-by: Roy <royvou@hotmailcom>
2020-07-14 17:54:21 -07:00
Alekhya
f59abe23c3
Fix for File Not Found exception while indexing invalid Package App (#4971)
* Catching file not found exception

* removed unnecessary header files

* Added a string.empty check for installed location

* reusing package wrapper instead of package installing event args
2020-07-14 11:44:50 -07:00
Divyansh Srivastava
74412766fa
Remove redundant code from Wox project (#4878)
* Removed unnecessary files from wox

Removed themes, images and unused xaml files

* Removed unused functions from settings view model

* Removed update manager

* Cleaned helper class

* Delete SingletonWindowOpener.cs

* nit fixes
2020-07-14 09:05:21 -07:00
Ivan Stošić
39b0401c55
Allow selecting multiple adjacent zones even when they slightly overlap (#4974) 2020-07-14 14:51:24 +02:00
Niels Laute
5f0e8d3d8e
[PowerToys Run] Updated (plugin) icons with MDL2 (#4149)
* Updated (plugin) icons with MDL2

* Image wasn't updating

* Based on feedback, updated app icon and windowwalker icon

* Updated app icon

* Updated Window Walker icon

* Change build action / Copy to output directory to None and Do Not Copy - like it was originally

* Fix

* Fix

* Resized images

* Added theme awereness based on somil55s PR

* Added theming to Shell and WindowWalker

* Revert "Added theming to Shell and WindowWalker"

This reverts commit f492c4efdb.

* Revert "Added theme awereness based on somil55s PR"

This reverts commit 8edd3226be.

* Typo fix

* Added new theming support for the new Calculator, Shell and WindowWalker icons

* Added Unit test reference back in
2020-07-13 22:59:19 -07:00
Arjun Balgovind
6a9badd31b
[Keyboard Manager] Cleanup header file references to improve incremental build time (#4880)
* Remove WinUI include in KeyboardManagerState.h

* Changed include steps

* Clean up headers in KeyboardManagerUI except XamlBridge.h

* Cleaned up headers in KeyboardManager common and test

* Cleaned up headers in KeyboardManager project

* Removed headers from XamlBridge

* Removed some headers from kbm common pch

* Added MP flag to reduce build time

* Added missing include
2020-07-13 11:49:09 -07:00
Arjun Balgovind
7db5d6a307
[Keyboard Manager] Fixed app-specific shortcut causing app to lose focus scenario (#4902)
* Fixed focus issue and added tests

* Changed key names

* Use constant instead of hardcoded empty string
2020-07-10 17:53:41 -07:00
Arjun Balgovind
bb2049411b
[Keyboard Manager] Add JSON support for App Specific shortcuts (#4840)
* Enable app specific shortcut remapping

* Fixed lowercase function call

* Add test file

* Moved GetForegroundProcess to II and added tests

* Fixed runtime error while testing due to heap allocation across dll boundary

* Renamed function

* Changed shortcutBuffer type

* Linked App specific UI to backend

* Added shortcut validation logic on TextBox LostFocus handler

* Moved Validate function and changed default text

* Changed to case insensitive warning check

* Changed to case insensitive warning check at OnClickAccept

* Fixed alignment and spacing issues

* Added app-specific JSON support in backend

* Updated landing page

* Make listview horizontally scrollable

* Added tests

* Consider all case variants of All Apps in textbox to be global shortcuts
2020-07-10 17:07:28 -07:00
Divyansh Srivastava
653ae777d5
Packaged apps test (#4921)
* Added wrapper for PackageManager and Package class

* Added tests for package in development and framework mode

* Renamed UWP test file

* Improved readability of UWP tests
2020-07-10 13:43:02 -07:00
Niels Laute
ec803d63c8
[Run] Updated tooltip styling and fixed casing (#4877)
* Added custom tooltip style (with theming support) that represents the UWP tooltip style.

* Removed unnecessary space in text

* Fixed run as admin casing

* Fixed casing for Indexer plugin
2020-07-10 12:06:57 -07:00
Ivan Stošić
412d80efe3
[FancyZones] Hold Ctrl to select any number of zones (#4850)
* Started work

* Did something, not yet sure that it works

* Sort of works

* Cleari highlighted zones when using Ctrl after leaving a monitor

* Remove unnecessary line

* Enhanced UX. Maybe refactor?

* Changed the logic behind zone selection when dragging

* Various fixups
2020-07-10 11:06:01 +02:00
ryanbodrug-microsoft
b1d662a5b1
Improving performance of Adding and Removing Packaged Apps (#4521) (#4900)
* Merging in Theme changes and moving win32Tests to Microsoft.Plugin.Program.UnitTests

* Fixing message format for exception

* Changing test structure.  Need to add unit tests.

* Updating packagerepository comment based on pr feedback

* Fixing potential race condition in ListRepository.  Now internally implemented as a concurrent dictionary.

* Removing unecessary implementation of IRepository interface as this is implemented by the base class.

* Restoring checks for invalid uwp apps based on PR feedback. This was accidentally removed when moving the initialize outside the constructor.

* Fixing comments

* Adding newline to end of file for IProgramRepository
2020-07-09 13:14:53 -07:00
ryanbodrug-microsoft
12d9d59d85
Revert "Improving performance of Adding and Removing Packaged Apps" (#4898)
* Revert "Adding newline to end of file for IProgramRepository"

This reverts commit d55cac80bf.

* Revert "Fixing comments"

This reverts commit a1ecdc9bfa.

* Revert "Restoring checks for invalid uwp apps based on PR feedback. This was accidentally removed when moving the initialize outside the constructor."

This reverts commit 0e8c1cb0fd.

* Revert "Removing unecessary implementation of IRepository interface as this is implemented by the base class."

This reverts commit 1c724280f5.

* Revert "Fixing potential race condition in ListRepository.  Now internally implemented as a concurrent dictionary."

This reverts commit 9ff8246a9d.

* Revert "Updating packagerepository comment based on pr feedback"

This reverts commit 2c45956030.

* Revert "Changing test structure.  Need to add unit tests."

This reverts commit 1c267a55d5.

* Revert "Fixing message format for exception"

This reverts commit f60bdc3dd4.

* Revert "Merging in Theme changes and moving win32Tests to Microsoft.Plugin.Program.UnitTests"

This reverts commit 030dfc2370.
2020-07-09 12:10:48 -07:00
Enrico Giordani
b13e719ab3
Update version to 0.19.2 (#4896) 2020-07-09 18:17:30 +02:00
Arjun Balgovind
451aea87aa
Added dummy key event to prevent Start Menu from popping up (#4874) 2020-07-09 08:14:47 -07:00
ryanbodrug-microsoft
d55cac80bf Adding newline to end of file for IProgramRepository 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
a1ecdc9bfa Fixing comments 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
0e8c1cb0fd Restoring checks for invalid uwp apps based on PR feedback. This was accidentally removed when moving the initialize outside the constructor. 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
1c724280f5 Removing unecessary implementation of IRepository interface as this is implemented by the base class. 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
9ff8246a9d Fixing potential race condition in ListRepository. Now internally implemented as a concurrent dictionary. 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
2c45956030 Updating packagerepository comment based on pr feedback 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
1c267a55d5 Changing test structure. Need to add unit tests. 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
f60bdc3dd4 Fixing message format for exception 2020-07-09 07:02:19 -07:00
ryanbodrug-microsoft
030dfc2370 Merging in Theme changes and moving win32Tests to Microsoft.Plugin.Program.UnitTests 2020-07-09 07:02:19 -07:00
Arjun Balgovind
4634085402
[Keyboard Manager] Add app-specific shortcuts to Remap shortcuts UI (#4804)
* Enable app specific shortcut remapping

* Fixed lowercase function call

* Add test file

* Moved GetForegroundProcess to II and added tests

* Fixed runtime error while testing due to heap allocation across dll boundary

* Renamed function

* Changed shortcutBuffer type

* Linked App specific UI to backend

* Added shortcut validation logic on TextBox LostFocus handler

* Moved Validate function and changed default text

* Changed to case insensitive warning check

* Changed to case insensitive warning check at OnClickAccept

* Fixed alignment and spacing issues
2020-07-08 16:24:30 -07:00
Alekhya
411140c3ea
Add run as admin context menu item for application results returned by the Indexer Plugin (#4807)
* Added run as admin context menu item to apps returned by indexer plugin

* Added a test and localized strings

* localize strings

* Add more tests for folder and other file types

* fixed run as admin -> run as administrator

* resolved merge conflict

* refactored tests

* moved common code to helper and added logs

* moved start process to the helper class

* added more info in a comment

* fixed count in tests as open in console was added

* removed additional code that was added while fixing merge conflicts
2020-07-08 13:05:57 -07:00
Divyansh Srivastava
638cd1dd48
[Run] Open in console functionality (#4739)
* Added open in console for indexer

* Added open in console fpr indexer and folder plugin

* Added open in console to program plugin

* Added string localization for program plugin

* Added test for win32 program

* Added test for win32 programs

* Added test for indexer plugin

* Localization for context menu title

* Added tests for folder plugin

* Added tests for indexer plugin

* Code cleanup

* Improved logging and nit fixes

* Updated tooltip for open in console

* Updates tests

* Removed subtitle property from contextmenuresult class

* Improved logging for context menu loaders
2020-07-08 09:56:26 -07:00
Yevhenii Holovachov
e3e6b23b7c
fixed unit tests (#4865) 2020-07-08 18:00:44 +03:00
vldmr11080
ac5a3e7a65
[FancyZones] Update app zone history on window removal (#4696)
* Update app zone history on every new window assignment to zone

* Compare window positions with already placed windows

* Remove window property only after processing window removal from zone
2020-07-08 16:59:36 +02:00
stefansjfw
106c316442
[FancyZones] Don't create new custom layout when applying Focus layout (#4755)
* Only persist data when applying existing layout if it is scaled

* Fix applying edited Focus layout

* Fix different Focus zone sizes in editor and engine

* Fix codestyle
2020-07-08 15:34:19 +02:00
vldmr11080
db229cf1bf
[FancyZones] Open window on active monitor (#4361)
* Initial design for opening window on active monitor

* Perform entire handling in DPI unaware thread

* Codestyle improvement

* Improve resizing mechanism and optimise code a bit

* Remove unneeded code, make simple helper functions inline

* Make this feature configurable

* Code optimization, improve positioning for some applications

* Retry positioning for certain applications

* Improve readability

* Address PR comments: Minor code style improvements

* Remove retries in custom positioning

* Position new toggle in settings menu
2020-07-08 10:37:42 +02:00
Alekhya
a314106b7e
Set the name(not the description) as the Title of the Result (#4745)
* Added tests to verify that the name is always set as the title and never the description

* removed AppType as an argument

* refactored code

* added comments

* localized strings

* removed empty constructor

* made setsubtitle private

* removed the mock Win32 class used for unit testing

* removed the UWP tests
2020-07-07 15:00:17 -07:00
Divyansh Srivastava
8d72bc0ea4
Tooltip for indexer and program plugin (#4589)
* Fix multiline title issue

* Added code to display tooltip for program and indexer plugin

* Added tests for Result class

* Theme based color for tooltip

* Added colors for tooltip

* Added string tags to tooltip

* Add initial show delay

* Seperated textbox for title and path
2020-07-07 13:02:39 -07:00
Arjun Balgovind
1533c9315f
[Keyboard Manager] Enable App-specific shortcuts in the KBM backend (#4628)
* Enable app specific shortcut remapping

* Fixed lowercase function call

* Add test file

* Moved GetForegroundProcess to II and added tests

* Fixed runtime error while testing due to heap allocation across dll boundary

* Renamed function

* Remove unused code

* Changed process checking step to include substrings

* Changed back to exact match included match without file extension
2020-07-06 16:45:53 -07:00
stefansjfw
70405045d7
[FancyZones] Remove Editor tmp files paths cmd args and make Editor 'debugable' easier (#4279)
* Remove Editor cmd args - tmp files
Add 'Debug mode' startup for Editor

* Remove fixed device info string

* Move if file exist check

* Add enum to improve readability

* Introduce ParseDeviceMode enum

* Organize strings

* Move title to localizable strings
2020-07-06 17:40:25 +02:00
vldmr11080
3d623506a8
[FancyZones] Invalidate cached work areas when display resolution or taskbar position changes (#4800)
* Invalidate cached work areas when display resolution or taskbar position changes

* Update comments in code
2020-07-06 17:34:28 +02:00
stefansjfw
11df74c292
Fix different grid layout shown by editor than the engine (#4758) 2020-07-06 17:04:40 +02:00
Nkateko
a935d69408
added null value handle for image resizer size input (#4721)
* addle null value handle for image resizer size input

* check for negative withd and height

* check for negative withd and height

* Update ImageSize.cs

Co-authored-by: Lavius Motileng <laviusntk>
2020-07-03 15:40:53 -07:00
Arjun
cffe0196e2 Added unit tests 2020-07-03 11:08:21 -07:00
Arjun
ac2a9deb75 Changed flags for newly pressed key after invoking shortcut 2020-07-03 11:08:21 -07:00
Alekhya
282e0adfe2
Removed the race condition (#4735) 2020-07-03 10:25:11 -07:00
Alekhya
ce60bcedb0
Add keyboard shortcut in tooltip for context menu items (#4702)
* Folder plugin - copy path

* indexer plugin - localized

* removed program plugin reference as it was not needed

* program plugin localized

* shell plugin localized

* removed extra semi colon

* Added loc files in other languages as well for indexer
2020-07-03 09:42:44 -07:00
Mehmet Murat Akburak
c9fd409650
Add trailing slash to OutDir (#4708) 2020-07-03 19:37:16 +03:00
Arjun Balgovind
8a908aa33f
Rework the HotkeyManager and KeyboardHook interop classes (#4710)
* Use GetAsyncKeyState calls and remove additional thread usage

* Removed Environment.Exit
2020-07-03 08:21:06 -07:00
Enrico Giordani
f9a5242e75
[FancyZones] draw active zones on top of inactive zones (#4727) 2020-07-03 17:04:52 +02:00
Divyansh Srivastava
7dabcc00ed
Added fix to update text on navigation using up/down arrow (#4626)
* Added fix to update text on navigation using up/down arrow

* Fix incorrect alignment with ghost text

* Added tests
2020-07-02 18:29:39 -07:00
Alekhya
18f4e9db31
Fix for Memory issue with context menu items (#4597)
* Added the inotifyPropertyChanged to all the properties and that stops the memory for shooting up

* some more inotify properties added

(cherry picked from commit 26fa05d9b661dadc5ab0257d540ab838a07c43a6)

* Revert "some more inotify properties added"

This reverts commit 845a94c9b2.

* Removed unnecessary inotifypropertychanged interfaces and cleaned up the code

* removed the ctrl+c from folder plugin

* removed unnecessary init

* Added unit test to check if PropertyChanged is called

* renamed var

* refactored the tests

* formatting and adding comments

* changed access modifier in test

* Used observable collection instead of a list

* clearing the observable collection instead of setting it to a new one
2020-07-02 13:48:41 -07:00
Clint Rutkas
593ab6b014
unifying a lot of test packages (#4667)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-02 11:02:05 -07:00
Arjun Balgovind
656c33e942
Moved each test class to a separate file (#4592) 2020-07-02 10:25:57 -07:00
Clint Rutkas
4330338285
adjustment for #3191 (#4674)
* adjustment for #3191

* forgot DE

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-02 10:09:25 -07:00
Clint Rutkas
44c41d52b2
upgrading wincppwinrt across the board (#4669)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-02 09:42:51 -07:00
Clint Rutkas
449a3f479f
unified mahapps (#4664)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-07-02 09:42:31 -07:00
Divyansh Srivastava
159a7c4947
Removed undeclared binding (#4590) 2020-07-02 09:32:53 -07:00
Mehmet Murat Akburak
30f442d774
[PowerRename] upper/lower/titlecase transform feature (#4183)
* Add basic transform functionality

* Add basic transform functionality

* Change toupper/tolower/isspace to towupper/towlower/towisspace. For loops omitted if possible.

* Avoid wcslen() in for statement

* Avoid wcslen() in for statement

* Add basic transform functionality

* Change toupper/tolower/isspace to towupper/towlower/towisspace. For loops omitted if possible.

* Avoid wcslen() in for statement

* Avoid wcslen() in for statement

* Add basic transform functionality

* Change toupper/tolower/isspace to towupper/towlower/towisspace. For loops omitted if possible.

* Avoid wcslen() in for statement

* Adjust Powerrename Interface

* Add trimming rename string

* Remove leading and trailing spaces from rename string

* Add support for transforming only item name or extension. Temporarily remove trimming to refactor. Change CAPITALIZED to TITLECASE

* Fix bug when search for area is empty

* Add trimming back with refactor(leading spaces, trailing spaces, trailing dots)

* Now supports transforming when search area is empty

* Add smarter titlecase

Transformation breaks when new filename contains an unusable character (\/?:*?"<>|)
These characters need to be removed from new name anyway.

* minor bugfix

* Add unittests, contains failing tests

* Remove unnecessary/failing tests

* remove generated file

* some code formatting and fix memory leak issues

* Use proper allocation, change int to size_t

* Refactor. Move transforming to Helpers.cpp

* Refactor. Move trimming to Helpers.cpp

* Change StrDup to SHStrDup. Some refactoring.

* Fix memery leak, add proper result controls, use newNameToUse in functon calls becaause it is where the final form of the string is tracked

* Change declarations of strings, add proper result controls

* Slightly widen the labels to cover the whole text

* Add extended characters support

* Rename a variable

* Correctly identify the last word for titlecase

* Add empty line to last line of resource.h
2020-07-02 11:52:01 +03:00
Yevhenii Holovachov
e8685de7f7
[FancyZones] Fixed shift behavior (#4653) 2020-07-01 18:23:57 +03:00
Ivan Stošić
4c08b591f1
[FancyZones] Restore size of zoned windows (#4463)
* Started work

* I can't debug anything, cleaning

* Added settings, [[Not Tested]]

Not even compiled

* Tested, the most basic features work

* Refactor, add RestoreSize

* Added DPI awareness

* Fixed a potential issue with resizing zoned windows

* Fixup: Potentially unsafe memory-layout of std::pair replaced with std::array

* Fixup: Use .data() instead of a pointer

* Further refactoring

* Integrated Win+Arrow keys with the Restore size feature

* Fixed an issue where window's on-screen position is not restored properly

* Fixed a bug pointed out by Enrico
2020-07-01 15:36:05 +02:00
Andrey Nekrasov
16528888df
Shortcut guide: add support for hotkeys + comments (#4517) 2020-07-01 12:37:50 +03:00
Andrey Nekrasov
738b5f5707
PowerLauncher: fix disabling by adjusting OpenProcess params (#4577) 2020-07-01 12:36:26 +03:00
Enrico Giordani
17343210c0
Now working on 0.19.1 (#4602) 2020-06-30 18:40:16 +02:00
Arjun Balgovind
0dd17cc175
Cleanup null reference fix with correct code practice (#4587)
* Fixed null reference exception on context menu buttons

* Cleaned up fix with correct practices
2020-06-29 15:47:10 -07:00
Arjun Balgovind
16e56c4edb
Fixed null reference exception on context menu buttons (#4586) 2020-06-29 13:47:35 -07:00
Yevhenii Holovachov
f46b876fd6
Removed hook creating from constructor (#4572) 2020-06-29 18:19:43 +03:00
Niels Laute
014c26be25
Fix for visual glitch (#4537) 2020-06-27 09:39:02 -07:00
Divyansh Srivastava
d3b10d0d4d
Theme aware plugin (#4499)
* Migrate theme manager to infrastructure and added it as input to public API instance

* Working event-delegate for PublicAPIInstance

* Theme aware UWP applications

* Theme aware program plugin

* Update query icon on theme change

* Theme aware calculator plugin

* Fix issue with query running before theme change

* Theme based changes in ImageLoader

* Removed ErrorIcon direct references and added references from ImageLoader

* Nit fixes

* Removed unnecessary TODO in UWP.cs

* Added preference to theme based icons

* Added IDisposable interfaces to unsubscribe events
2020-06-26 17:42:06 -07:00
Niels Laute
d9597d5ad5
[Run] Minor UX tweaks (#4526)
* Tweaked the shadows so it's conform to Windows standards. Fixed margins so UI elements are more aligned

* Fix
2020-06-26 16:12:26 -07:00
Arjun Balgovind
55272e5ea2
Fix settings issue where settings.json would get reset on runner startup (#4524)
* Added flag to avoid saving before modules is initialized

* Added comment
2020-06-26 14:46:47 -07:00
Alekhya
d17fc86fa4
[PT Run] Clear binary and json storage files on version upgrade (#4479)
* Clean termination of powertoys process.

* Fixed issue with run not responding to WM_CLOSE

* Fixed serialization error in pinyin and image cache

* Fixed merge conflict

* Fixed nit wrt to master

* Basic framework of clearing up of cache is working

* formatting

* removed the default argument of load

* fixed nit comment

* rewriting the PowerToys version

* Each storage file has an associated version file which helps decide whether or not to delete that file on loading

* removed unnecessary reference

* renamed file to StoragePowerToysVersionInfo

* adding log files

* Checking whether the version strings are null, if so, we would clear the cache

* Added filepath to log files to make it more informative

* fixed nit naming

* using lesser than to compare instead of portable version

Co-authored-by: Divyansh Srivastava <somm14divi@gmail.com>
2020-06-26 11:54:42 -07:00
Arjun Balgovind
e3e02aa30b
Skip ErrorIcon and DefaultIcon while resizing the dictionary (#4520)
* Skip ErrorIcon and DefaultIcon while resizing the dictionary

* Removed autogenerated using statement
2020-06-26 11:30:04 -07:00
Arjun Balgovind
403f53a397
Fixed ghost text casing (#4498) 2020-06-26 10:29:34 -07:00
Alekhya
bfd79e1af2
reduced the description weight by half (#4519) 2020-06-26 10:20:54 -07:00
Alekhya
5745a984aa
Partial Fix for Memory issue - Limiting the number of ImageSources cached (#4433)
* reducing storage of images

* Added task.run

* cleaned up code and added comments

* Renamed variable

* refactored code

* Removed task.run because it was leading to race conditions in the concurrent dictionary and it was taking only upto 10 ms for reordering the dictionary

* Added comments and fixed variable name
2020-06-26 10:20:35 -07:00
Enrico Giordani
d98cb50d7a
Update version to 0.19.0 (#4518) 2020-06-26 19:00:27 +02:00
Yevhenii Holovachov
cc4864976a
Changed position of callback(false) call on disabling hook for shift (#4515) 2020-06-26 17:20:10 +03:00
Divyansh Srivastava
92fa8b7421
PowerToys Run cache issue (#4472)
* Clean termination of powertoys process.

* Fixed issue with run not responding to WM_CLOSE

* Fixed serialization error in pinyin and image cache

* Fixed merge conflict

* Fixed nit wrt to master

* Fixed undeterministic behaviour of Environment.Exit function

* Update timing for terminate process
2020-06-25 16:03:50 -07:00
Arjun Balgovind
aad2e8012b
Add environment exit statement (#4496) 2020-06-25 14:21:09 -07:00
Arjun Balgovind
f1b6e6570c
Fix remapping issues to Home/PgUp and other keys which are also present on NumPad (#4398)
* Added extended key flag to more keys

* Add test for extended key flag

* Move shlwapi.lib reference

* Added shcore ref

* Fixed pipeline incompatibility

* Fixed lib declaration in common

* Fixed formatting

* Remove unused statements

* removed another statement
2020-06-24 20:28:54 -07:00
Arjun Balgovind
8e758507b1
Enable code analysis on Keyboard Manager projects (#4455)
* Enable code analysis and fix GetTickCount warning

* Fix arithmetic casting warning
2020-06-24 14:55:02 -07:00
Arjun Balgovind
2601d8b702
Fix missing dlls in MSI for 0.19 (#4474)
* Add/remove missing dlls and add search.interop nuget package ref

* Fixed formatting
2020-06-24 14:48:16 -07:00
Yevhenii Holovachov
fa0545e4b3
Added info to ManagedCommon project (#4468) 2020-06-24 18:36:37 +03:00
Yevhenii Holovachov
690208fd4e
Fixed info for powerrename, previewpane and shortcutguide (#4447) 2020-06-24 18:08:55 +03:00
Chakib Ljazouli
3272575f70
Dynamic dialog titles for Key/Shortcuts remapping (#4251)
* Fix typo in dialog title

* Pass Remap Keys/Shortcuts dialog titles as argument
2020-06-23 20:00:58 -07:00
ryanbodrug-microsoft
fad3142a47 Fix for warning: Error CA1806 BringProcessToForeground calls SendInput but does not use the HRESULT or error code that the method returns. This could lead to unexpected behavior in error conditions or low-resource situations. Use the result in a conditional statement, assign the result to a variable, or pass it as an argument to another method. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\MainWindow.xaml.cs 73 Active 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
1f74dcff14 Changing 'Any CPU' to 'x64' for Managed Common project. 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
62c7183922 Setting 'Treat warnings as errors' to 'All' 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
ef73b0a07f Setting treat warnings as errors to true for release as well. 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
ec7d42d1fd Supressing NU1701 warning on known working nuget packages. This will allow us to turn warnings as errors on. 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
256a17f2c9 Fixing:
Error CS0436 The type 'ActionKeywords' in 'C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\ActionKeywords.xaml.cs' conflicts with the imported type 'ActionKeywords' in 'Wox, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'. Using the type defined in 'C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\ActionKeywords.xaml.cs'. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\ActionKeywords.xaml 7 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
165ffed9e6 Fix CA 1060 by moving PInvokes to a common NativeMethodsClass
Severity Code Description Project File Line Suppression State
Warning CA1060 Move pinvokes to native methods class PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\App.xaml.cs 24 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
b89d6d78ef Fix or the following warning. Removing unused ReportWindow from Launcher
Warning CA1812 ReportWindow is an internal class that is apparently never instantiated. If so, remove the code from the assembly. If this class is intended to contain only static members, make it static (Shared in Visual Basic). PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\ReportWindow.xaml.cs 15 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
6890561723 Severity Code Description Project File Line Suppression State
Warning CA1307 The behavior of 'string.IndexOf(string)' could vary based on the current user's locale settings. Replace this call in 'PowerLauncher.MainWindow.ListView_FirstItem(string)' with a call to 'string.IndexOf(string, System.StringComparison)'. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\MainWindow.xaml.cs 269 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
849ce04def Fix for Warning CA1823:
Severity Code Description Project File Line Suppression State
Warning CA1823 Unused field '_progressBarStoryboard'. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\MainWindow.xaml.cs 27 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
a29baf19d0 Fix for:
Severity Code Description Project File Line Suppression State
Warning CA2007 Consider calling ConfigureAwait on the awaited task PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\MainWindow.xaml.cs 305 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
10d6a1fa54 Severity Code Description Project File Line Suppression State
Warning CA1801 Parameter text of method DelayedCheck is never used. Remove the parameter or use it in the method body. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\MainWindow.xaml.cs 303 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
6ea181c286 Fix for:
Warning CA1820 Test for empty strings using 'string.Length' property or 'string.IsNullOrEmpty' method instead of an Equality check. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\MainWindow.xaml.cs 291 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
2d890603c6 Fix for Warning CA1822 Member 'Hyperlink' does not access instance data and can be marked as static PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\ReportWindow.xaml.cs 45 Active 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
d1ca30a28f Fix for Warning CA1822 Member 'GetHighContrastBaseType' does not access instance data and can be marked as static PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\ThemeManager.cs 65 Active 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
35fccf8af8 Fix for Warning CA1031: Removing catch, as it doesn't recover from the exception, but hides the exception from showing up in crash reports / telemetry.
Warning CA1031 Modify '.ctor' to catch a more specific allowed exception type, or rethrow the exception. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\SettingsWatcher.cs 33 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
f5baa56e05 Fix for CA1031.
Settings.json is locked by the settings application and throws a system IO Exception.   This should be syncronized with the settings application, but for now I'm just fixing the exception to be more specific and not hide unexpected exceptions.

System.IO.IOException: 'The process cannot access the file 'C:\Users\ryanbod\AppData\Local\Microsoft\PowerToys\PowerToys Run\settings.json' because it is being used by another process.'

Severity Code Description Project File Line Suppression State
Warning CA1031 Modify 'OverloadSettings' to catch a more specific allowed exception type, or rethrow the exception. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\SettingsWatcher.cs 76 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
d2c1be5c2d Warning CA2002 Do not lock on objects with weak identity PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\SettingsWatcher.cs 43 Active 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
fd6525a9de Fix for Warning CA1822 :
Severity Code Description Project File Line Suppression State
Warning CA1822 Member 'ConvertHotkey' does not access instance data and can be marked as static PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\SettingsWatcher.cs 85 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
ba03a134da Fix for CA1822:
Severity Code Description Project File Line Suppression State
Warning CA1822 Member 'WaitForPowerToysRunner' does not access instance data and can be marked as static PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\App.xaml.cs 130 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
9184c64ecb Fix for
Severity Code Description Project File Line Suppression State
Warning CA1401 P/Invoke method 'OpenProcess' should not be visible PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\App.xaml.cs 125 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
653a9664e4 Removing warnings relative to passing in unlocalized string literals. Most of these pertain to debug messages and aren't user facing. We may want to revisit localizing these later. 2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
51d0cedb29 Fix for:
Warning CA1806 Main calls TryParse but does not explicitly check whether the conversion succeeded. Either use the return value in a conditional statement or verify that the call site expects that the out argument will be set to the default value when the conversion fails. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\App.xaml.cs 45 Active
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
fa6d1bb23c Fix for:
Warning CA1062 In externally visible method 'void App.Main(string[] args)', validate parameter 'args' is non-null before using it. If appropriate, throw an ArgumentNullException when the argument is null or add a Code Contract precondition asserting non-null argument. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\App.xaml.cs
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
0f3b154699 Fix for the following:
Warning CA1001 Type 'MainWindow' owns disposable field(s) '_firstDeleteTimer' but is not disposable PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\MainWindow.xaml.cs

    Warning CA1816 Change App.Dispose() to call GC.SuppressFinalize(object). This will prevent derived types that introduce a finalizer from needing to re-implement 'IDisposable' to call it. PowerLauncher C:\Repos\PowerToys\src\modules\launcher\PowerLauncher\App.xaml.cs
2020-06-23 17:51:17 -07:00
ryanbodrug-microsoft
d6e2b096ca Adding static analysis (Microsoft.CodeAnalysis.FxCopAnalyzers) to PowerLauncher Project 2020-06-23 17:51:17 -07:00
Arjun Balgovind
2104a1250e
Added step to dispose the keyboard hook object (#4449) 2020-06-23 17:19:36 -07:00
Alekhya
ca99f60964
[PT Run] Find applications using the PATH env variable (#4418)
* Search for programs in the path env variable

* removing list of disabled programs

* Added env variable string to classify apps

* reverted the fullpath change

* removing full paths while calculating dups

* removed dups

* removed debugging code

* Renamed to run command

* Added condition to filter run commands unless there is an exact match

* renamed occurances to RUN COMMAND

* localized the subtitle - Run command

* Added tests

* add fullpath back to hash calculation

* renamed the function
2020-06-23 11:40:11 -07:00
Yevhenii Holovachov
147c08bd71
Added info to FancyZones, KeyboardManager and PowerLauncher projects (#4445) 2020-06-23 18:36:39 +03:00
Yevhenii Holovachov
ad440f70fa
Added info to projects inside root, tests and common folders (#4413) 2020-06-23 16:53:16 +03:00
Yevhenii Holovachov
bb22155482
Added info to new settings projects (#4417) 2020-06-23 16:47:07 +03:00
Seraphima Zykova
5c1999b3d0
[Settings] 'Check for updates' button behavior changed (#4385) 2020-06-23 15:53:02 +03:00
Arjun Balgovind
87f0fcfd52
Added hack to show window if open (#4428) 2020-06-22 15:38:55 -07:00
Clint Rutkas
f6d53bc337
upgrade xaml based nuget packages (#4426)
* Settings packages updated

* removing WinUI references from wox base

* removing unneeded reference

Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-06-22 15:23:39 -07:00
Arjun Balgovind
720fad80c3
Fix Launcher focus for most cases (#4362)
* Add SendInput hack

* Cleaned up code

* Fixed formatting

* Moved Activate fn call

* Add more comments with link to issue
2020-06-22 14:47:33 -07:00
Divyansh Srivastava
196055e50e
Index Desktop Applications (#4422)
* Added support to index desktop app

* Fixed dedup for url files

* Added internet shortcut scheme for epic games

* Added test for internet shortcut dedup

* Updated hostname for steam game
2020-06-22 12:34:57 -07:00
Andrey Nekrasov
73125574e6
MSI: fix include dirs causing MSI pre-build event fail to build (#4415) 2020-06-22 17:00:39 +03:00
Ivan Stošić
27a35a0388
Fixed an issue with the shift key (#4411) 2020-06-22 15:57:30 +02:00
Andrey Nekrasov
8c6085b933
Runner: move Launcher to its own folder and simplify dll loading (#4379) 2020-06-22 13:01:33 +03:00
Andrey Nekrasov
bef14f551e
FancyZones: fix possible crash in GetWorkAreasByDesktopId (#4380) 2020-06-22 12:46:54 +03:00
Yevhenii Holovachov
e56c2eb6ca
Fixed version property to pull from Version.props in C# projects (#4382) 2020-06-22 12:14:00 +03:00
Lavius Motileng
165365473f
[Settings][Fix][Image Resizer ] Unused text box when selecting custom percent in new settings (#4344)
* save general settings to file upon launch

* ImageResizer: Added flags to disable and hide extra boxes

Co-authored-by: Lavius Motileng <laviusmotileng-ms>
2020-06-19 13:18:37 -07:00
Andrey Nekrasov
3bdd9a850f
Runner: improve debugging experience with hooks (#4377)
* Runner: improve debugging experience with hooks
2020-06-19 14:13:38 +03:00
yuyoyuppe
b84ea020f2
fixup! forgot to rename 2020-06-19 13:27:29 +03:00
Seraphima Zykova
90efc5740f
[WinAppDriver tests] Affection on user setting files fix (#4186) 2020-06-19 11:09:12 +03:00
Alekhya
c78e6588ad
init description (#4391) 2020-06-18 17:15:21 -07:00
Divyansh Srivastava
a21a3827fd
Remove hidden files from indexer results (#4325)
* Added functionality to not display hidden files

* Added interfaces for seperating db layer

* Updated variable naming and refactored Database connection class

* Added tests for WindowsSearchAPI class

* Fixed nit with braces

* Added function to test that all connections from database are closed
2020-06-18 15:42:28 -07:00
yuyoyuppe
2effbd0baf
Runner: improve debugging experience with hooks 2020-06-18 14:27:20 +03:00
Andrey Nekrasov
7ed03c8b90
Runner: autoupdate should prefer .exe installer instead of .msi (#4216) 2020-06-18 13:43:09 +03:00
Niels Laute
59ce90e924
[PowerToys Run] Vertical scrollbar for results list (#4343)
* Enabling vertical scrollbar and colors

* Extending the list under the scrollbar

* Fix
2020-06-17 09:48:30 -07:00
Yevhenii Holovachov
da38e6a23d
[FancyZones] Changed Shift key capture method (#4274)
* Used windows hook to capture shift key instead of getting state of key on window move
2020-06-17 16:06:16 +03:00
vldmr11080
698e5ec6ea
[FancyZones] Move window into last known position on active work area (if possible) (#4218)
* Move window into last known position on active work area (if possible)

* Refactor code to avoid double checks

* Address PR comments

* Perform all HWND checks at one place

* Improve handling of active/primary work area in app zone history

* Address PR comments: naming, arguments checks

* Rename some functions to increase readability

* Implement special handling in 2+ monitor scenario

* Minor naming change

* Simplify

* Improve readability

* Remove blank line

* Don't move away from secondary monitor if there is no app zone history

* Update comment

* FancyZonesEditor should not be zoned

* Preserve width and height (if possible) when opening on active monitor

* Maintain w/h whenever possible

* Remove scaling, add window coordinates on active monitor top-left corner

* If there is no app zone history on secondary screen, fallback to default windows behavior.
2020-06-17 11:55:14 +02:00
ryanbodrug-microsoft
7f25e3ba97
Allowing launcher to be run as startup project with no command line args (#4267) 2020-06-16 10:53:27 -07:00
Clint Rutkas
1a3500cad3
moving the editor config out the the root folder (#4289)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
2020-06-16 08:59:38 -07:00
stefansjfw
31c30a7602
Apply general settings on runner startup (#4302) 2020-06-16 10:55:15 +02:00
Mehmet Murat Akburak
014f3b9873
[PowerRename] capturing groups fix (#4181)
* Fix capturing group bug when Match All Occurrences is not checked

* Capture groups are now available when Match All Occurences option is not selected

* Bug fix when capture group is indicated with leading zeros. $01 should be considered as $1 etc

* Use flags in regex_replace() when Match All Occurences is not selected

Now the behaviour is consistent with how regex works when Match All Occurences is selected.
2020-06-16 11:04:14 +03:00
Arjun Balgovind
49cbcf01c6
Add workaround for IME Caps Lock issue (#4123)
* Add workaround for Japanese IME Caps Lock issue

* Changed tweak to reset modifier key rather than Caps Lock

* added tests

* Fixed test comment

* Moved environment initialization in KBM tests to TEST_METHOD_INITIALIZE
2020-06-15 16:48:00 -07:00
stefansjfw
f8cc129f04
[FancyZones] Move Trace::VirtualDesktopChange (#4320)
* Move Trace::VirtualDesktopChange to catch only the actual VD changes

* Update the check

* Add double check
2020-06-15 19:44:07 +02:00
Alekhya
236c1208e6
PWAs should not show up when searching for the main app (#4221)
* Search shows up steam games

* Formatting

* Filtering only those steam shortcuts which run an application

* Using equals instead of ==

* PWAs should not show up when searching for the main app

* Modified the subtitle to say progressive web application

* renamed to web application

* To search for web applications for all chromium based browsers

* Renamed it to WebApplication

* Added unit tests and refactored code

* made string global const

* Added localization tags

* Added a separate function for localization as the IPublic API was not available to all

* Removed unnecessary references and variables

* Update src/modules/launcher/Plugins/Microsoft.Plugin.Program/Languages/de.xaml

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>

* Added enum for application types

Co-authored-by: htcfreek <61519853+htcfreek@users.noreply.github.com>
2020-06-12 13:11:24 -07:00
Davide Giacometti
4c70e75bfc
fix launcher network path (#4224) 2020-06-12 11:42:31 -07:00
pekspro
e8c5f3a882
Fixes null reference exception. (#3436) 2020-06-12 11:42:13 -07:00
Divyansh Srivastava
302df56ee1
Added support to run apps in development mode (#4217) 2020-06-11 18:24:45 -07:00
chrisgch
ccfc4d68f3
Setting WS_CHILD on preview handler (#3048) 2020-06-11 15:32:35 -07:00
Arjun Balgovind
071ea1dc97
KBM - Set up tests for keyboard hook remapping logic (#4004)
* Add test proj, refactor proj with filters, and move single remap function to a separate header

* Moved all methods to header files

* remove more unused commented code

* Reverted sln file

* Fixed sln file

* Added interface wrapping SendInput calls

* fixed formatting

* Created test mock class

* Added keyboard input logic

* Fixed compilation errors and added nuget reference to CppWinRT

* Added tests for single key remapping

* Refactored code for adding shortcut remap tests

* Separated test classes

* Fixed tests in release mode

* Added more tests

* Resolved comments
2020-06-11 13:07:46 -07:00
Tomas Agustin Raies
670033c4da
[Settings/Run] LowLevel Keyboard hooking for Hotkeys (#3825)
* [Launcher/Settings] Low Level Keyboard Hooks

* [Run] LowLevel Keyboard Hook for Hotkeys

* Prevent shortcuts from auto repeating when keeping the keys pressed down
2020-06-11 12:59:36 -07:00
Arjun Balgovind
fa7e4cc817
Tweaked OS Detection project structure and added os check for PT Run (#4253)
* Tweaked OS Detection project structure and added check in Launcher

* Reverted formatter change to minimize diff
2020-06-11 11:47:15 -07:00
Clint Rutkas
67c8d80190
Safeguarding end user links in settings (#4226)
* first adjustment to wiki move

* Image Resizer and deleting imgs for FZ

* updating stuff to aka links

* updating app to leverage aka links

* moving files to wiki

* KBM adjustment

* updating

* getting PT Run moved over

* Shortcut guide and fixing launcher's readme text

* Update README.md

* img for shortcut guide moved to wiki

* updated setting img to be aka link as well
2020-06-11 10:16:39 -07:00
vldmr11080
792ce53992
Fix invalid namespace (#4259) 2020-06-11 17:03:02 +02:00
vldmr11080
b0a25f59d9
[Installer] Restart explorer.exe programatically after successful update (#4215)
* Restart explorer.exe programatically after successful update

* Move RestartManager related code into common

* Add newline at the end of files

* Note that explorer.exe should not be localized string
2020-06-11 10:09:06 +02:00
Niels Laute
d76234c112
[PT Run] Updated themes (dark/light/highcontrast) (#4119)
* Updated themes (dark/light/highcontrast)

* Updated semi-transparent colors to opague colors (for ClearType)

* Added theme brushes (light/dark/high contrast) for scrollbar.
2020-06-10 11:15:15 -07:00
Yevhenii Holovachov
6fdfd3b9e7
[PT Run] Closing PT Run and new settings app when PowerToys is not running (#3853)
Closing PowerLauncher, FZ Editor and new settings app when PowerToys is not running
2020-06-10 20:58:34 +03:00
dependabot[bot]
38350a1ae4
Bump websocket-extensions from 0.1.3 to 0.1.4 in /src/settings-web (#4108)
Bumps [websocket-extensions](https://github.com/faye/websocket-extensions-node) from 0.1.3 to 0.1.4.
- [Release notes](https://github.com/faye/websocket-extensions-node/releases)
- [Changelog](https://github.com/faye/websocket-extensions-node/blob/master/CHANGELOG.md)
- [Commits](https://github.com/faye/websocket-extensions-node/compare/0.1.3...0.1.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-06-10 19:36:53 +02:00
Alekhya
ce2bba751c
Fix for Steam games not showing up (#4124)
* Search shows up steam games

* Formatting

* Filtering only those steam shortcuts which run an application

* Using equals instead of ==

* Case change in Internet shortcut
2020-06-10 10:34:48 -07:00
Arjun Balgovind
f149736a20
Add additional shortcut validation logic in Remap Shortcuts UI (#4068)
* Add more validation logic for shortcut remaps UI

* Fixed a bug in CheckRepeatedModifier logic
2020-06-10 08:25:41 -07:00
Alekhya
40330be123
Added case insensitive hash code calculation (#4206) 2020-06-09 14:12:53 -07:00
Divyansh Srivastava
93af4fc6b0
Fixed initial focus on WPF issue (#4113)
* Fixed initial focus on WPF issue

* Added comment for property change

* Updated function naming for visibility callback
2020-06-09 09:16:20 -07:00
Josh Soref
b574d4e388
Spelling - remaining code changes (#3963)
* spelling: commit

* spelling: exclusion

* spelling: initial

* spelling: occurred

* spelling: programmatically

* spelling: should

* spelling: successfully

* spelling: committed

* spelling: directly
2020-06-09 10:11:02 +02:00
Ivan Stošić
eb4b429e19
[Action runner] Support running generic targets as non-elevated (#3863)
* Initial work, not tested

* Forgot the most important part

* Use target argument instead of hardcoded string

* Removed old way of running Launcher

* Completed rebase, updated some code
2020-06-08 22:53:40 +02:00
Josh Soref
21929b1db2
Spelling misc (#4199)
* spelling: accessibility

* spelling: occurrences
2020-06-08 22:43:59 +02:00
Clint Rutkas
a5197ee039
making alt-f4 ignored (#4023) 2020-06-08 13:18:42 -07:00
Niels Laute
9ae4dd3dfe
Updated the PT Run icon to #4041 (#4114) 2020-06-05 15:45:18 -07:00
Alekhya
d0e4dabe90
Fix for UWP icons not showing up (#4008)
* Added fix for UWP icons not showing up

* updated comment and reversed the list of target sizes

* find the icon closest in size to the appIcon size

* Remove nlog reference that was added by mistake
2020-06-05 15:05:00 -07:00
Arjun Balgovind
3edb360d79
Fix remapping from Num Lock (#4083)
* Added num lock remap workaround

* Added comments

* Changed to 2 suppressed key events

* Fixed typos
2020-06-05 12:54:52 -07:00
Arjun Balgovind
f5285b48b1
Fix remapping to Alt+Tab/Win+Space style shortcuts (#3965)
* Add skip to currently invoked shortcut code - should change no behavior

* Fixed Alt tab issue

* Added comment

* Added step to check if original shortcut action key should be pressed

* Fix number of cases in comment
2020-06-05 11:39:38 -07:00
Alekhya
c01b76e098
Fix for PWAs and command prompt not showing up as the first result (#4020)
* Added code which increments the score for the app without any arguments

* Removed magic number and added var
2020-06-05 11:34:16 -07:00
Divyansh Srivastava
6adb47c447
Theming for powertoys run (#4007)
* Removed Wox Theme Manager

* Added Light and dark theme and template for high contrast theme

* Updated themeManager to remove strings

* Fixed issue with high contrast theme not being applied

* Fixed formatting

* Updated MSI to include dll for Mahapps and controlzex

* Added support for multiple high contrast themes
2020-06-05 09:58:30 -07:00
vldmr11080
b0b2d3a727
[FancyZones] App zone history on multiple desktops (#3932)
* Remove app zone history belonging to deleted virtual desktop.

* Implement support fancy zones app zone history on multiple desktops.

* Break when device id is located to avoid unnecessary loop iterations.

* Fix failing unit tests after JSONHelpers API changes.

* Use valid UUIDs in json helper unit tests.

* User properly formated test data in app zone history unit tests.

* Don't delete entire app history when moving out of zone on one desktop.
2020-06-05 17:25:52 +02:00
Yevhenii Holovachov
8410d7b08e
[FancyZones] Secondary mouse buttons click to toggle zones activation (#3989)
* Changed option name in settings, changed behaviour of zones activation by mouse to switch
* Removed IsDragEnabled from ZoneWindow
2020-06-05 17:53:08 +03:00
Enrico Giordani
e6408a0c37 [runner] Change way of dropping privileges to start PT Run 2020-06-05 10:35:11 +02:00
Seraphima Zykova
e96c82b171
Uniform style for button designations in settings (#4070) 2020-06-05 09:51:09 +03:00
Enrico Giordani
ee31813a0d Now working on 0.18.3 2020-06-05 07:27:45 +02:00
Lavius Motileng
ac62fd6204
added error handling for FZ Hotkeys (#4057)
* added error handling for FZ Hotkeys

* moved hint to hot key control text

* updated icon size 16px

* updated styling and fixed typos

* fixed typo

* moved text to string resource

Co-authored-by: Lavius Motileng <laviusmotileng-ms>
2020-06-04 14:52:04 -07:00
Lavius Motileng
30cb7e62fd
removed restrictions for image-resizer file format (#3377) 2020-06-04 11:05:28 -07:00
smiley
7c7ccc3a07
[PowerToys Run] Add "ignore hotkeys in fullscreen" setting (#3262) (#3604)
Connect Wox's existing "ignore hotkeys in fullscreen mode" setting to PowerLauncher and the PowerToys settings UI.

This allows PowerLauncher to ignore hotkeys if any application is currently in fullscreen mode, whether it's real exclusive fullscreen or borderless windowed mode. This applies to things like fullscreen games, video and presentations but not maximized windows.
2020-06-04 10:21:16 -07:00
vldmr11080
fb3f4fa0a8
Connect appZoneHistory settings with rest of the stack in settings v2 (#4047) 2020-06-04 14:33:03 +02:00
stefansjfw
2b62244806
Cleanup Editor cmd args (#4022) 2020-06-04 13:01:42 +02:00
stefansjfw
f5dc197e8b
[example_powertoy] Remove example_powertoy (#3955)
* Remove example_powertoy

* Address PR comments
2020-06-04 12:28:30 +02:00
Josh Soref
e6060048bd spelling: restart 2020-06-04 11:38:21 +02:00
Alekhya
8cddd595d4
Fix for File explorer not showing up and multiple notepads (#3969)
* reverted the dedup code, file explorer shows up but so do duplicates

* Fixed file explorer and dedup

* Formatting

* Added tests for all the cases

* Formatting

* Tests

* take name and exe into consideration while calculating hash

* unique primes while calculating hash code
2020-06-02 14:36:32 -07:00
vldmr11080
1c7b07d614
Remove workarounds related to 0000 dekstop GUID. (#3931) 2020-06-02 12:06:36 +02:00
Niels Laute
0d59de5767 Fixed spacing issue 2020-06-02 11:26:58 +02:00
Niels Laute
e3613c54e9 'Autocomplete' is more common than 'autocompletion' 2020-06-02 11:26:58 +02:00
Niels Laute
5956e6d9c1 Updated strings for PowerRename 2020-06-02 11:26:58 +02:00
Niels Laute
ec895f271b Page header is now center aligned with first item, similiar to W10 Settings 2020-06-02 11:26:58 +02:00
Niels Laute
751f30e316 Changed numberbox to slider for FZ. Added opacity value textblock for all sliders 2020-06-02 11:26:58 +02:00
Niels Laute
cee8253cd3 Fixed width for controls so they are nicely aligned 2020-06-02 11:26:58 +02:00
stefansjfw
ae4cb6e372
Move FancyZones to separate build&install dir (#3961) 2020-06-02 10:48:07 +02:00
Arjun
398f976f3e Added KeyboardManager directory 2020-06-02 10:26:21 +02:00
Alekhya
a8d67a1c60
Take space into consideration while calculating the first matched index (#3874) 2020-06-01 15:25:14 -07:00
Divyansh Srivastava
397b1533f0
Somil55/merge wpf to master (#3840)
* Basic WPF searchbox working

* Updated key navigation and removed coldstart for searhbox

* refactored and added code back in commented

* Removed XAML Island references

* Basic searchbox+listview working

* Getting a bit more back

* got color there

* Result list bit better now

* Added image loader for WPF Image

* Partially got the context menus rendering again

* adjusting coldstart to load, control will load with main form

* getting context menus back

* mouse over works now

* Click now works, started to remove Win.XAML references

* being a bit more forcusful on focus

* Shadow text is not aligned

* fixing focus if listbox was used

* small tweak to fix shadow text

* inputs don't work but gotta figure out why.  commenting out

* preview text

* adding back in delay

* fixed height issue

* Applied the correct context button styles

* Created custom ItemContainerStyle to fix the blue highlights behind the command buttons

* Applied the correct highlight / mouseover styling

* Removed vertical scrollbar in listview

* fixed for alt-space prompt

* Fixed right click focus issue

* Somil55/wpf modifier keys (#3378)

* Removed DPI change as it was not required

* Global key hooks for context menu items

* Updated Key for shell, folder and indexer plugin

* Updated key mapping for indexer plugin

* Somil55/wpf context menu selection (#3389)

* Removed DPI change as it was not required

* Global key hooks for context menu items

* Updated Key for shell, folder and indexer plugin

* Updated key mapping for indexer plugin

* Add trigger to selection on tabbing

* Minor shadow adjustments so its more similiar to default shell shadow. Added intro/outro animations

* Added UWP-like scrollbar style for the results list

* Fixed formating and naming

* Removed Powerlauncher UI project

* Update PowerToys.sln

* Commented out scrollbar and fade in/out animations

* Added missing features from UWP branch

* Fixed formatting for Product.wxs

* Add dragging to WPF window

Co-authored-by: Clint Rutkas <clint@rutkas.com>
Co-authored-by: Niels Laute <niels.laute@live.nl>
2020-06-01 12:35:37 -07:00
stefansjfw
84a197299f
[KeyboardManager&Installer] Move Keyboard Manager to separat build&install folder (#3949)
* Move Keyboard Manager to separat build&install folder

* Update pipeline
2020-06-01 18:29:40 +02:00
Alekhya
d2dfbff832
Add resource only when it is not already present (#3842) 2020-06-01 08:17:28 -07:00