mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-16 19:57:57 +01:00
Set window walker overview link (#1772)
This commit is contained in:
@@ -1,3 +1,6 @@
|
||||
#include "resource.h"
|
||||
#include "../../../common/version.h"
|
||||
|
||||
1 VERSIONINFO
|
||||
FILEVERSION 0,1,0,0
|
||||
PRODUCTVERSION 0,1,0,0
|
||||
@@ -15,14 +18,14 @@ BEGIN
|
||||
BEGIN
|
||||
BLOCK "040904b0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "Company Name"
|
||||
VALUE "CompanyName", COMPANY_NAME
|
||||
VALUE "FileDescription", "$projectname$ Module"
|
||||
VALUE "FileVersion", "0.1.0.0"
|
||||
VALUE "FileVersion", FILE_VERSION_STRING
|
||||
VALUE "InternalName", "$projectname$"
|
||||
VALUE "LegalCopyright", "Copyright (C) 2019 Company Name"
|
||||
VALUE "LegalCopyright", COPYRIGHT_NOTE
|
||||
VALUE "OriginalFilename", "$projectname$.dll"
|
||||
VALUE "ProductName", "$projectname$"
|
||||
VALUE "ProductVersion", "0.1.0.0"
|
||||
VALUE "ProductVersion", PRODUCT_VERSION_STRING
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
@@ -30,3 +33,10 @@ BEGIN
|
||||
VALUE "Translation", 0x409, 1200
|
||||
END
|
||||
END
|
||||
|
||||
STRINGTABLE
|
||||
BEGIN
|
||||
IDS_MODULE_NAME L"Window Walker"
|
||||
IDS_GENERAL_DESCRIPTION L"A text-based Alt+Tab with search. Use Ctrl+Win to pop up."
|
||||
IDS_OVERVIEW_LINK L"https://github.com/microsoft/PowerToys/blob/master/src/modules/windowwalker"
|
||||
END
|
||||
@@ -4,6 +4,7 @@
|
||||
#include <interface/win_hook_event_data.h>
|
||||
#include <common/settings_objects.h>
|
||||
#include "trace.h"
|
||||
#include "resource.h"
|
||||
|
||||
extern "C" IMAGE_DOS_HEADER __ImageBase;
|
||||
|
||||
@@ -24,11 +25,6 @@ BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserv
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
// The PowerToy name that will be shown in the settings.
|
||||
const static wchar_t* MODULE_NAME = L"Window Walker";
|
||||
// Add a description that will we shown in the module settings page.
|
||||
const static wchar_t* MODULE_DESC = L"A text-based Alt+Tab with search. Use Ctrl+Win to pop up";
|
||||
|
||||
// These are the properties shown in the Settings page.
|
||||
struct ModuleSettings
|
||||
{
|
||||
@@ -39,6 +35,9 @@ struct ModuleSettings
|
||||
class WindowWalker : public PowertoyModuleIface
|
||||
{
|
||||
private:
|
||||
// The PowerToy name that will be show in the settings.
|
||||
std::wstring m_appName;
|
||||
|
||||
// The PowerToy state.
|
||||
bool m_enabled = false;
|
||||
|
||||
@@ -53,6 +52,7 @@ public:
|
||||
WindowWalker()
|
||||
{
|
||||
init_settings();
|
||||
m_appName = GET_RESOURCE_STRING(IDS_MODULE_NAME);
|
||||
};
|
||||
|
||||
// Destroy the powertoy and free memory
|
||||
@@ -69,7 +69,7 @@ public:
|
||||
// Return the display name of the powertoy, this will be cached by the runner
|
||||
virtual const wchar_t* get_name() override
|
||||
{
|
||||
return MODULE_NAME;
|
||||
return m_appName.c_str();
|
||||
}
|
||||
|
||||
// Return array of the names of all events that this powertoy listens for, with
|
||||
@@ -89,9 +89,11 @@ public:
|
||||
|
||||
// Create a Settings object.
|
||||
PowerToysSettings::Settings settings(hinstance, get_name());
|
||||
settings.set_description(MODULE_DESC);
|
||||
settings.set_description(GET_RESOURCE_STRING(IDS_GENERAL_DESCRIPTION));
|
||||
settings.set_overview_link(GET_RESOURCE_STRING(IDS_OVERVIEW_LINK));
|
||||
settings.set_icon_key(L"pt-window-walker");
|
||||
|
||||
|
||||
return settings.serialize_to_buffer(buffer, buffer_size);
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
#define IDS_MODULE_NAME 100
|
||||
#define IDS_GENERAL_DESCRIPTION 101
|
||||
#define IDS_OVERVIEW_LINK 102
|
||||
|
||||
Reference in New Issue
Block a user