Commit Graph

2503 Commits

Author SHA1 Message Date
Andrey Nekrasov
c1b1fe6371
Fix compilation errors for VS 16.8.1 (#8024)
* fix compilation issues for VS 16.8.* release

* - VS 16.8 changed its template instantiation model, so now the compiler checks the syntax used in template even when it's not instantiated. we were relying on that behavior to declare the list of required localized strings from a shared header => replacing that template with a macro.

* - fix 3 C++ `const auto&` bugs the new compiler was able to uncover

* - enabled /Zc:twoPhase- for bootstrapper and PowerToysSetupCustomActions to workaround 10.0.17134.0 headers' issue.

- PowerToysSetupCustomActions.vcxproj now uses 10.0.17134.0 instead of "latest" SDK

* - PowerToysSetupCustomActions project leverages `goto` operator's power extensively, and the new compiler was able to uncover new uninitialized variables behavior, restructured declarations and changed `NULL`s to `nullptr`s.

* - Fix unit FZ unit test compiler error

* - format FZS unit test source file

* fixup fz tests

* use /Zc:twoPhase- for common-md as well
2020-11-13 15:57:01 +03:00
csigs
97fcc8311f LEGO: check in for master to temporary branch. 2020-11-13 12:07:05 +00:00
csigs
ba42b192b8 LEGO: check in for master to temporary branch. 2020-11-13 00:05:15 +00:00
csigs
f2ad8086a7 LEGO: check in for master to temporary branch. 2020-11-12 17:49:09 +00:00
ivan100sic
0013282012 Formatting 2020-11-12 12:41:11 +01:00
stefansjfw
102f42928c
[FancyZones Editor][Accessibility] Default focused elements in all FancyZones Editor windows (#7971)
* Default focused elements

* Fix focus when starting editor from settings
2020-11-12 10:08:17 +01:00
csigs
9eb8377cea LEGO: check in for master to temporary branch. 2020-11-11 23:06:14 +00:00
Clint Rutkas
c756bad83c fix test 2020-11-11 14:39:30 -08:00
Clint Rutkas
62f2e6fb8e removed mahapps dep, did lighter weight ControlzEx. Need to add these to WSX 2020-11-11 14:14:34 -08:00
Clint Rutkas
2c0656142a added in a few comments. pointed automatedname to static resource 2020-11-11 13:35:42 -08:00
Clint Rutkas
bc22631340 adding disposed pattern 2020-11-11 13:18:15 -08:00
Clint Rutkas
56af486790
Merge pull request #7983 from microsoft/dev/crutkas/madeWithLove
added made with love
2020-11-11 12:49:52 -08:00
ivan100sic
f2469415d2 Separate a big function call to several functions 2020-11-11 17:57:24 +01:00
csigs
5c2e5e14fa LEGO: check in for master to temporary branch. 2020-11-11 11:06:15 +00:00
Clint Rutkas
3b62f2ceba added made with 2020-11-10 16:37:17 -08:00
csigs
8a86253958 LEGO: check in for master to temporary branch. 2020-11-10 23:06:24 +00:00
Clint Rutkas
8f11874449 Merge branch 'master' into lego/hb_2939_20201108230556187 2020-11-10 14:43:16 -08:00
Niels Laute
e4e2586939 Light theme fix 2020-11-10 20:17:47 +01:00
Niels Laute
1e00d8cdaf Updated styling 2020-11-10 20:13:39 +01:00
Clint Rutkas
7ecf01737d
Merge pull request #7974 from microsoft/lego/hb_2939_20201110110635301
LEGO: Pull request from lego/hb_2939_20201110110635301 to master
2020-11-10 08:52:03 -08:00
Clint Rutkas
23083decbb
Merge pull request #7946 from microsoft/lego/hb_2939_20201109110559091
LEGO: Pull request from lego/hb_2939_20201109110559091 to master
2020-11-10 08:51:39 -08:00
vldmr11080
0a8bc1a63c
Enable keyboard accessibility for template and custom layout items (#7977) 2020-11-10 16:24:20 +01:00
vldmr11080
db61c6b643
[FancyZones] Localize names of predefined layotus (#7973)
* Localize strings in Settings.cs

* Add comment to resource variable
2020-11-10 16:15:30 +01:00
Andrey Nekrasov
48cf167a3c
runner: localize tray menu item labels (#7959)
* runner: localize tray menu item labels

* fixup: please the electronic machinery

* Update src/runner/Resources.resx

Co-authored-by: Enrico Giordani <enricogior@users.noreply.github.com>

Co-authored-by: Enrico Giordani <enricogior@users.noreply.github.com>
2020-11-10 15:56:05 +03:00
csigs
248135dffb LEGO: check in for master to temporary branch. 2020-11-10 11:06:37 +00:00
Clint Rutkas
7bbcde9310 Merge branch 'master' into lego/hb_2939_20201109110559091 2020-11-09 16:36:17 -08:00
Clint Rutkas
a0e14fd37c
Merge pull request #7964 from microsoft/lego/hb_2939_20201109230607691
LEGO: Pull request from lego/hb_2939_20201109230607691 to master
2020-11-09 16:30:34 -08:00
Clint Rutkas
b3a2df7bf9
Merge pull request #7962 from microsoft/dev/crutkas/updateFody
upgrading PropertyChanged.Fody 3.3.+
2020-11-09 15:35:20 -08:00
Clint Rutkas
2d61b69ff5
Merge pull request #7555 from TobiasSekan/MoreColorsTakeTwo
[ColorPicker] Add HSB, HSI, HWB and NCol color representation
2020-11-09 15:16:32 -08:00
csigs
a6031a46a2 LEGO: check in for master to temporary branch. 2020-11-09 23:06:08 +00:00
Clint Rutkas
0266776a3e upgrading fody, https://github.com/microsoft/PowerToys/pull/7858 may be hard since we removed core 2020-11-09 10:57:37 -08:00
Davide Giacometti
701c119986
fix log file not created (#7935) 2020-11-09 19:39:02 +01:00
Raphael Horber
8c7f2b6a74
PowerRename: Add Lookbehind (#7571)
* Add boost-regex library

* If enabled use boost lib for regex

Add property `_useBoostLib` to `CPowerRenameRegEx`. If enabled for
replacements with regular expressions the Boost Library is used instead
of the Standard Library.

* Extend signatures to create RegEx with Boost

Extend create and constructor singatures of `CPowerRenameRegEx` with an
option to enable (or disabled, which is default) the Boost Library.

* Verify Lookbehind fails with STD library

To verify that the boost library is disabled as expected, check if a
lookbehind fails.

* Add Unit tests for RegEx with Boost

Add unit tests to verify regex replacement with Boost Library. They are
copied and adapted from the Standard Library tests.

* Improve verify capturing groups test with Boost

It is possible to use a capturing group followed by numbers as
replacement if the group number is enclosed in curly braces.
Added test cases based on the Standard Library tests.

* Add useBoostLib to settings interface

* Get library option from settings object

* Reduce signatures of RegEx by "useBoost"

Remove the parameter added in 19105cf, as it became obsolete.

* Settings: Read useBoostLib from JSON file

* Add UseBoostLib Option to UI

* Boost Lib label states the regex syntax difference

* Fix Regex with Boost Lib tests

- Do not load settings another time in CPowerRenameRegEx ctor
- Set flag correctly in standard library regex tests

* Add "lookbehind" to dictionary

* change Library to lowercase, and also add a comment

As suggested by @enricogior.

Co-authored-by: Enrico Giordani <enricogior@users.noreply.github.com>

* Change Library to lowercase and add a comment

 As suggested by @enricogior.

Co-authored-by: Enrico Giordani <enricogior@users.noreply.github.com>
2020-11-09 19:13:43 +01:00
yuyoyuppe
5a9e1b14cb localization: Fix action_runner/runner folder names 2020-11-09 20:00:45 +03:00
csigs
e27c5e3043 LEGO: check in for master to temporary branch. 2020-11-09 11:06:00 +00:00
Sekan, Tobias
83b2ffd0c9 Commit to Re-Trigger Github PR 2020-11-09 09:50:55 +01:00
Sekan, Tobias
d192e6feb6 fix misspellings 2020-11-09 06:30:36 +01:00
Sekan, Tobias
36f55ae80c Address feedback 2020-11-09 06:03:39 +01:00
Sekan, Tobias
dc2751aa38 Address feedback + cleanup 2020-11-09 06:03:33 +01:00
Sekan, Tobias
c0501bdc02 Address feedback 2020-11-09 06:02:48 +01:00
Sekan, Tobias
25d7df470f Address feedback - fix swapped color name (UI) 2020-11-09 06:02:48 +01:00
Sekan, Tobias
e2dd94332b fix wrong name 2020-11-09 06:02:48 +01:00
Sekan, Tobias
c4eccb3666 correct order + correct docu 2020-11-09 06:02:48 +01:00
Sekan, Tobias
767ce22019 Add test for HWB and NCol converter 2020-11-09 06:02:48 +01:00
Sekan, Tobias
b087deadcb Add HSI test and fix HSI calculation 2020-11-09 06:02:48 +01:00
Sekan, Tobias
71f9299485 Add HSI calculation 2020-11-09 06:02:48 +01:00
Sekan, Tobias
57dd0ce113 Add Ncol, HWB, HSB color format + cleanup 2020-11-09 06:02:41 +01:00
csigs
090ddafade LEGO: check in for master to temporary branch. 2020-11-08 23:05:56 +00:00
Niels Laute
fbc82f01b2 Added foreground brush 2020-11-08 22:18:47 +01:00
Niels Laute
3e874f8bb2 Fixed x symbol not showing 2020-11-08 22:08:56 +01:00
Niels Laute
9ffbc0f08c Reverted dev changes 2020-11-08 21:07:05 +01:00
Niels Laute
9e5edaba71 Accesibility improvements 2020-11-08 21:02:26 +01:00
Niels Laute
aafab46456 UI improvements 2020-11-08 20:09:07 +01:00
Niels Laute
14f905dbfd Updates themes 2020-11-08 14:41:51 +01:00
Niels Laute
f424e93d34 Added logic that disables input boxes when Custom size is not selected 2020-11-08 14:35:00 +01:00
Niels Laute
0d43ea2bb9 Accesibility improvements + updated colors 2020-11-08 14:31:57 +01:00
Niels Laute
da36371448 Keyboard accesibility fix 2020-11-07 21:36:59 +01:00
Niels Laute
edbbc69f4f Updating UI and making it Fluent 2020-11-07 21:17:31 +01:00
Niels Laute
36fd030075 Added theming support 2020-11-07 15:51:38 +01:00
csigs
f23925340e LEGO: check in for master to temporary branch. 2020-11-06 23:05:30 +00:00
vldmr11080
65ce8c760d
Specify focus rectangle color when focused by keyboard (#7899) 2020-11-06 23:23:22 +01:00
vldmr11080
9402f4ad02
Add name property for delete buton (#7895) 2020-11-06 20:12:53 +01:00
Mykhailo Pylyp
db8be6ad10
fix clipped text issue (#7897) 2020-11-06 19:08:25 +02:00
Clint Rutkas
4d92a7e250
Merge pull request #7815 from pi1024e/patch-1
Remove unneeded variable for GetLastError();
2020-11-06 09:00:36 -08:00
Clint Rutkas
5b85e942f1
Merge pull request #7816 from pi1024e/headers
Replace deprecated C headers with their C++ equivalent
2020-11-06 09:00:23 -08:00
Clint Rutkas
8a55d327b6
Merge pull request #7886 from microsoft/lego/hb_2939_20201105230548571
LEGO: Pull request from lego/hb_2939_20201105230548571 to master
2020-11-06 08:59:05 -08:00
Mykhailo Pylyp
8a1d2611d8
[KBM] Added banded rows (#7787)
* Added banded rows

* Fix build after merge

* accessibility names, capturing static row indexes by lambda

* Fix position of targetApp textbox

* fix wrong path for textbox
2020-11-06 16:24:11 +02:00
csigs
42b4989846 LEGO: check in for master to temporary branch. 2020-11-05 23:05:49 +00:00
Clint Rutkas
74b04e4f2c
Merge pull request #7881 from microsoft/action_runner-loc-redirection-bug
Update LocProject.json
2020-11-05 12:56:03 -08:00
Clint Rutkas
8a317e5af2
Merge pull request #7820 from davidegiacometti/issue-7336
[PT Run] Wox.Core merged into PowerLauncher
2020-11-05 12:20:42 -08:00
Clint Rutkas
7f21ebe82b
Update LocProject.json 2020-11-05 11:25:03 -08:00
Clint Rutkas
f0889b13dd
Merge pull request #7865 from microsoft/lego/hb_2939_20201105110544059
LEGO: Pull request from lego/hb_2939_20201105110544059 to master
2020-11-05 10:25:02 -08:00
Clint Rutkas
3bc4820d90
Merge pull request #7857 from microsoft/lego/hb_2939_20201104230553771
LEGO: Pull request from lego/hb_2939_20201104230553771 to master
2020-11-05 09:17:40 -08:00
vldmr11080
fc1feab7ec
Add descriptive name for zone increment/decrement buttons (#7867) 2020-11-05 15:01:07 +01:00
stefansjfw
8fa04fe2cf
Add Grid Layout Editor name property (#7831) 2020-11-05 12:24:10 +01:00
csigs
4786b64b93 LEGO: check in for master to temporary branch. 2020-11-05 11:05:44 +00:00
Enrico Giordani
50a8884c32
[common, shortcutguide] move d2d files from common to scg (#7844)
Also remove d2d classes from common documentation
2020-11-05 10:38:46 +01:00
Niels Laute
1dc1531104
[Settings] Added hyperlink button to wiki for keys that can't be remapped (#7826) 2020-11-05 09:04:26 +01:00
Niels Laute
82bc61e620
[Settings] Added delete button tooltip to Image Resizer page (#7827) 2020-11-05 09:02:31 +01:00
Enrico Giordani
ad15a5e26f
[settings-web] Update packages (#7849) 2020-11-05 08:53:27 +01:00
csigs
8e43a3ca0b LEGO: check in for master to temporary branch. 2020-11-04 23:05:54 +00:00
Clint Rutkas
e3b70bc8b9
Merge pull request #7851 from microsoft/dev/crutkas/adjustStrings
Change to FancyZone Layout Editor and added in comments
2020-11-04 13:32:20 -08:00
Davide
37f711b234 Wox.Core project deleted 2020-11-04 20:36:47 +01:00
Clint Rutkas
045837a888 adding in comments for FZ layout editor 2020-11-04 11:23:53 -08:00
Clint Rutkas
4b1ba511de shift to layout editor 2020-11-04 11:22:58 -08:00
Davide
1aa4008b36 Merge branch 'master' into issue-7336 2020-11-04 20:02:25 +01:00
Davide
21c1665678 fix release build 2020-11-04 19:57:55 +01:00
Clint Rutkas
083605fb85
Merge pull request #7842 from microsoft/lego/hb_2939_20201104110551356
LEGO: Pull request from lego/hb_2939_20201104110551356 to master
2020-11-04 06:38:52 -08:00
Clint Rutkas
7f6d8ba86c
Merge pull request #7618 from microsoft/dev/crutkas/upgradeNuget
Upgrading nuget packages
2020-11-04 06:38:08 -08:00
Mehmet Murat Akburak
1a64597fca
[PowerRename] Fix warnings and turn on treat warnings as errors (#7840)
* Fix 2 mentioned warnings

* Turn on treat warnings as errors

* Remove win32 configurations
2020-11-04 14:13:07 +03:00
csigs
ced25643e0 LEGO: check in for master to temporary branch. 2020-11-04 11:05:51 +00:00
Niels Laute
a34afd1ca2
[Settings] Updated FZ page (#7828) 2020-11-04 10:05:14 +01:00
Clint Rutkas
bd8c2ce774 more comments 2020-11-03 17:01:37 -08:00
Clint Rutkas
7508a73373
Merge pull request #7708 from jsoref/spelling
Spelling
2020-11-03 16:54:00 -08:00
Clint Rutkas
bdeb35ba3b change indexer to file search 2020-11-03 16:37:18 -08:00
Clint Rutkas
e6ccd5cf0d adding in comments, changing "PowerToys is up-to-date" 2020-11-03 16:36:59 -08:00
csigs
a6a4821380 LEGO: check in for master to temporary branch. 2020-11-03 23:06:05 +00:00
Davide
fdb39ca314 Wox.Core merged into PowerLauncher 2020-11-03 21:45:01 +01:00
pi1024e
859e674c11 Replace deprecated headers
To remove warnings about deprecated headers and for more robust C++, this replaces the deprecated C header with its C++ equivalent.
2020-11-03 13:59:35 -05:00
Clint Rutkas
aa1d6f7095
Merge branch 'master' into dev/crutkas/upgradeNuget 2020-11-03 10:57:50 -08:00
pi1024e
9c1ed88e5f
Remove unneeded variable for GetLastError();
No other usage of GetLastError has the result assigned to a variable first in this code, so it is better if we make check_user_is_admin the same in that regard.
2020-11-03 13:39:29 -05:00
Clint Rutkas
35cf50c796
Merge pull request #7808 from microsoft/lego/hb_2939_20201103110547248
LEGO: Pull request from lego/hb_2939_20201103110547248 to master
2020-11-03 09:59:34 -08:00
Clint Rutkas
f36584ce38
Merge pull request #7797 from microsoft/lego/hb_2939_20201102230612006
LEGO: Pull request from lego/hb_2939_20201102230612006 to master
2020-11-03 09:08:38 -08:00
csigs
8b39996577 LEGO: check in for master to temporary branch. 2020-11-03 11:05:47 +00:00
vldmr11080
78b2020669
[FancyZones] Adjust colors of secondary buttons to maintain 3:1 contrast ratio against white background (#7785)
* Adjust colors of secondary buttons to maintain 3:1 contrast ratio against white background

* Use white color withing Cancel button
2020-11-03 11:46:24 +01:00
Davide Giacometti
269b12226a
apply correct theme at startup (#7796) 2020-11-03 11:30:19 +01:00
yuyoyuppe
4228b9a772 ImageResizer: fix Color contrast of ComboBox 2020-11-03 12:42:19 +03:00
yuyoyuppe
c103a8a205 Image resizer: fix Color contrast of 'Resize Your Pictures' 2020-11-03 12:40:30 +03:00
Davide Giacometti
6e8337c563
[PT Run] Folder path starting with backslash (#7711)
* folder plugin path starting with backslash

* handle single \ input
2020-11-03 10:36:16 +01:00
yuyoyuppe
ccf02579e6 ImageResizer: skip Settings tab focus when hidden 2020-11-03 11:34:39 +03:00
vldmr11080
49811fc4b8
Adjust template tab non-highlighted color (#7638) 2020-11-03 09:25:36 +01:00
csigs
80d8144f1e LEGO: check in for master to temporary branch. 2020-11-02 23:06:13 +00:00
Clint Rutkas
7f6e2c308e
Merge pull request #7779 from microsoft/lego/hb_2939_20201102110603120
LEGO: Pull request from lego/hb_2939_20201102110603120 to master
2020-11-02 10:41:28 -08:00
Clint Rutkas
60f9a2f773
Merge pull request #7766 from microsoft/lego/hb_2939_20201101230540961
LEGO: Pull request from lego/hb_2939_20201101230540961 to master
2020-11-02 10:39:54 -08:00
Clint Rutkas
394482157e
Merge pull request #7756 from microsoft/lego/hb_2939_20201101110551694
LEGO: Pull request from lego/hb_2939_20201101110551694 to master
2020-11-02 10:23:46 -08:00
Clint Rutkas
a66b276e7d
Merge branch 'master' into spelling 2020-11-02 09:57:48 -08:00
Clint Rutkas
0a23f1e35c
Merge pull request #7745 from microsoft/lego/hb_2939_20201031230528313
LEGO: Pull request from lego/hb_2939_20201031230528313 to master
2020-11-02 09:56:17 -08:00
Clint Rutkas
c47e61d136
Merge pull request #7725 from microsoft/lego/hb_2939_20201031110538538
LEGO: Pull request from lego/hb_2939_20201031110538538 to master
2020-11-02 09:49:32 -08:00
Clint Rutkas
f3f57ba79b
Merge pull request #7717 from microsoft/lego/hb_2939_20201030230621684
LEGO: Pull request from lego/hb_2939_20201030230621684 to master
2020-11-02 09:41:03 -08:00
Clint Rutkas
41ee6e706a
Merge pull request #7718 from microsoft/dev/crutkas/langAdjustmentForLearning
Change "Module overview" to "Learn more" in settings menu
2020-11-02 09:38:54 -08:00
P-Storm
0d4017fe1a
Io abstraction (#7293)
Co-authored-by: p-storm <paul.de.man@gmail.com>
2020-11-02 18:33:43 +01:00
csigs
11f9a64737 LEGO: check in for master to temporary branch. 2020-11-02 11:06:04 +00:00
Davide Giacometti
5c3eef0112
fix test project color picker ui (#7713) 2020-11-02 12:00:56 +01:00
yuyoyuppe
fbd1108041 ImageResizer: fix hyperlink buttons role 2020-11-02 12:55:56 +03:00
stefansjfw
ebf81a6a03
Associate Name label with textbox (#7621) 2020-11-02 10:05:57 +01:00
yuyoyuppe
f33b3c771a common project localization: move out all updating strings
- finish localizing boostrapper/runner/action_runner
2020-11-02 12:03:32 +03:00
csigs
4a4b6c5589 LEGO: check in for master to temporary branch. 2020-11-01 23:05:41 +00:00
csigs
d7eafcb641 LEGO: check in for master to temporary branch. 2020-11-01 11:05:52 +00:00
csigs
4e0120493e LEGO: check in for master to temporary branch. 2020-10-31 23:05:28 +00:00
csigs
954b483e4f LEGO: check in for master to temporary branch. 2020-10-31 11:05:39 +00:00
punker76
fa1448163a
[PowerLauncher] Fix getting theme changed event for and between HighContrast setting 2020-10-31 11:58:52 +01:00
punker76
f89b98e7c7
[PowerLauncher] Fix getting theme changed event 2020-10-31 11:58:52 +01:00
punker76
44af8f30f8
[PowerLauncher] Remove MahApps dependency and add own LibraryThemeProvider 2020-10-31 11:58:52 +01:00
Mehmet Murat Akburak
7ff8b97006
[PowerRename] Split "status message" / "items count label" into two lines (#7696)
* Split status message

* Use spaces instead of tabs
2020-10-31 11:25:16 +03:00
Clint Rutkas
62c9184658
Update Resources.resw 2020-10-31 01:15:52 -07:00
Clint Rutkas
ce0f0322af adding in comment for do not loc product names 2020-10-30 16:54:27 -07:00
Clint Rutkas
462d64ab7a Changed title and started adding in additional comments. 2020-10-30 16:52:00 -07:00
Avneet Kaur
2c5b9b4d52
Audit culture bugs (#7707)
* Added comments and fixed CultureInfo /  StringComparison where appropriate

* Addressed comments

* Fixed comment
2020-10-30 16:43:09 -07:00
csigs
dddafc8944 LEGO: check in for master to temporary branch. 2020-10-30 23:06:23 +00:00
Alekhya
bd34127cd4
Add unit tests for incorrect settings json files (#7644)
* added some test config files

* Added tests for each powertoy to ensure that they don't crash even when there is a corrupt json

* Revert "Added tests for each powertoy to ensure that they don't crash even when there is a corrupt json"

This reverts commit fe3ed40902.

* Revert "added some test config files"

This reverts commit d08928423a.

* add a settings utils to test that a default item is returned when the json file is corrupt
2020-10-30 12:53:57 -07:00
Josh Soref
98c9199f0e spelling: verify
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:49 -04:00
Josh Soref
7e942a366c spelling: update
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:41 -04:00
Josh Soref
ad9f88c487 spelling: synchronized
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:32 -04:00
Josh Soref
7442162cc0 spelling: suppressions
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:28 -04:00
Josh Soref
3e20672efe spelling: specification
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:40:57 -04:00
Josh Soref
2b235e0827 spelling: specific
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:24 -04:00
Josh Soref
8720a0dcdf spelling: source
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:20 -04:00
Josh Soref
d116298d2f spelling: shortcut
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:16 -04:00
Josh Soref
fd8b99bd8c spelling: retrieving
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:11 -04:00
Josh Soref
724ca6f06e spelling: representation
Signed-off-by: Josh Soref <jsoref@users.noreply.github.com>
2020-10-30 14:42:07 -04:00
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