Commit graph

8 commits

Author SHA1 Message Date
Stefan Markovic 5cfbd72fa8
[PowerRename] Fluent UX (#13678)
* PowerRename new UI

* Add scrollviewer

* Don't deploy PowerRenameUI_new

* Visual updates

* Visual updates

* Updates

* Update Resources.resw

* Added docs button

* Update MainWindow.xaml

* Wire Docs button

* RegEx -> regular expressions

* Update Show only renamed list on search/replace text changed

* Update Show only renamed list on search/replace text changed - proper fix
Set searchTerm to NULL when cleared - fix Show only renamed files on clear searchTerm

* Files/folders input error handling

* Fix renaming with keeping UI window opened

After renaming folder, all of it's children need path update.
Without path update, further renaming of children items would
fail.

* Update only children, not all items with greater depth

* Fix dictionary false positives

* Remove .NET dep

* Rename PowerRenameUI_new to PowerRenameUILib
Rename executable PowerRenameUIHost to PowerRename

Co-authored-by: Laute <Niels.Laute@philips.com>
2021-10-25 14:40:19 +01:00
Mehmet Murat Akburak da22e21a0e
[PowerRename] Fix tests inconsistency, improve test performance (#8129)
* Move retrieveing file attibutes to PowerRenameRegex
Move file attributes unit tests to PowerRenameRegexTests
Add file time field to MockPowerRenameItem

* Add file attributes unittests to PowerRenameManagerTests

* Change variable name

* Rearrange function arguments

* Check if file attributes are used only once

* Change variable name LocalTime -> fileTime, date -> time

* Set fileTime as a member of PowerRenameRegEx rather than passing as an argument

* Change function name isFileAttributesUsed() -> isFileTimeUsed()
Check before resetting fileTime

* Fix small bugs

* Fix typos

* Refactor for readability, move free calls to reachable places

* Fix search for area empty bug
searchTerm being empty is not an invalid argument rather it must return OK without any operation
Tests must check if Replace()  returns S_OK becuase later it checks its result

* Check return values of method calls in PowerRenameManager
Remove received argments checks from some methods because argument being null or empty string doesnt mean it is invalid or method fails

* Fix formatting. Remove overlooked comment. Fix error message.

* Change HRESULT declarations according to coding style

* Fix unhandled case. Refactor.
2020-12-14 10:28:12 +01: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
yuyoyuppe 303d1fef6b
PCH: remove headers which are actually could be changed (#950) 2019-12-17 11:21:46 +03:00
Chris Davis e328c5d505 * Fix crashing bug in event vector cleanup
* Fix warnings in settings.cpp
* Add settings to ui of powertoys
2019-11-11 20:58:39 -08:00
Chris Davis 1e89054897 * Ensure rename dialog is centered
* Ensure children are renamed before parent items
* Add settings handler
* Replace old text referencing smart rename with power rename
2019-11-11 11:00:42 -08:00
Chris Davis b892e731d9
Add new icon as well as telemetry (#563)
* Update icon and add telemetry calls

This change adds the new PowerRename icon and includes telemetry calls

* Ensure string is freed

* Update event naming convention

* Delete PowerRenameDemo.gif

Deleting this gif as I added it with a separate commit with the README.md update for PowerRename
2019-10-28 10:14:59 -07:00
Chris Davis e1d5dd263a
Initial add of PowerRename from SmartRename repo (#499)
* Initial add of PowerRename from SmartRename repo
2019-10-17 20:57:19 -07:00