/
githubmirror
/
PowerToys
Обзор
Документация
Войти
/
githubmirror
/
PowerToys
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/modules/NewPlus/NewShellExtensionContextMenu/template_item.h
40 строк
1 KB
Christian Gaarden Gaardmark
New+ Rename and Desktop icon positioning improvements (#48083)
5 часов назад
Не верифицирован
5 часов назад
b605fd3
Код
Авторство
О чём код?
#pragma once #include "pch.h" #include <filesystem> #include <iostream> #include <string> #include <map> using namespace Microsoft::WRL; namespace newplus { class template_item { public: template_item(const std::filesystem::path entry); std::wstring get_menu_title(const bool show_extension, const bool show_starting_digits, const bool show_resolved_variables) const; std::wstring get_target_filename(const bool include_starting_digits) const; std::wstring get_explorer_icon() const; HICON get_explorer_icon_handle() const; std::filesystem::path copy_object_to(const HWND window_handle, const std::filesystem::path destination) const; void refresh_target(const std::filesystem::path target_final_fullpath) const; void enter_rename_mode(const std::filesystem::path target_fullpath, const POINT mouse_position_at_invoke) const; std::filesystem::path path; private: static DWORD WINAPI rename_worker_thread_proc(void* parameter); static void rename_on_other_thread_workaround(const std::filesystem::path& target_fullpath, const POINT mouse_position_at_invoke); std::wstring remove_starting_digits_from_filename(std::wstring filename) const; }; }