diff options
Diffstat (limited to 'src/mir_app')
-rw-r--r-- | src/mir_app/src/FontService.cpp | 6 | ||||
-rw-r--r-- | src/mir_app/src/services.cpp | 12 |
2 files changed, 18 insertions, 0 deletions
diff --git a/src/mir_app/src/FontService.cpp b/src/mir_app/src/FontService.cpp index 7d553218ad..21790e4369 100644 --- a/src/mir_app/src/FontService.cpp +++ b/src/mir_app/src/FontService.cpp @@ -49,6 +49,9 @@ INT_PTR RegisterEffectW(WPARAM wParam, LPARAM lParam); INT_PTR GetEffect(WPARAM wParam, LPARAM lParam);
INT_PTR GetEffectW(WPARAM wParam, LPARAM lParam);
+INT_PTR ReloadFonts(WPARAM, LPARAM);
+INT_PTR ReloadColours(WPARAM, LPARAM);
+
static int OnModulesLoaded(WPARAM, LPARAM)
{
HookEvent(ME_OPT_INITIALISE, OptInit);
@@ -85,6 +88,9 @@ int LoadFontserviceModule(void) CreateServiceFunction(MS_EFFECT_GET, GetEffect);
CreateServiceFunction(MS_EFFECT_GETW, GetEffectW);
+ CreateServiceFunction(MS_FONT_RELOAD, ReloadFonts);
+ CreateServiceFunction(MS_COLOUR_RELOAD, ReloadColours);
+
hFontReloadEvent = CreateHookableEvent(ME_FONT_RELOAD);
hColourReloadEvent = CreateHookableEvent(ME_COLOUR_RELOAD);
diff --git a/src/mir_app/src/services.cpp b/src/mir_app/src/services.cpp index 2aef865789..22206c3800 100644 --- a/src/mir_app/src/services.cpp +++ b/src/mir_app/src/services.cpp @@ -323,6 +323,12 @@ INT_PTR GetFont(WPARAM wParam, LPARAM lParam) return ret;
}
+INT_PTR ReloadFonts(WPARAM, LPARAM)
+{
+ NotifyEventHooks(hFontReloadEvent, 0, 0);
+ return 0;
+}
+
/////////////////////////////////////////////////////////////////////////////////////////
MIR_APP_DLL(void) KillModuleFonts(int _hLang)
@@ -398,6 +404,12 @@ INT_PTR GetColour(WPARAM wParam, LPARAM) return sttGetColourWorker(&temp);
}
+INT_PTR ReloadColours(WPARAM, LPARAM)
+{
+ NotifyEventHooks(hColourReloadEvent, 0, 0);
+ return 0;
+}
+
/////////////////////////////////////////////////////////////////////////////////////////
MIR_APP_DLL(void) KillModuleColours(int _hLang)
|