From fbde8268b2f9488d22118ad3493431a144ab542a Mon Sep 17 00:00:00 2001 From: Brian Date: Tue, 15 Mar 2022 15:14:49 -0600 Subject: [PATCH] Manage dialog/Context menu: Rearrange various skin settings on the Manage dialog and context menu --- Language/Arabic.h | Bin 26748 -> 26868 bytes Language/Bulgarian.h | Bin 28488 -> 28602 bytes Language/ChineseSimplified.h | Bin 21986 -> 22078 bytes Language/ChineseTraditional.h | Bin 21960 -> 22052 bytes Language/Croatian.h | Bin 28164 -> 28286 bytes Language/Czech.h | Bin 28024 -> 28136 bytes Language/Danish.h | Bin 27866 -> 27978 bytes Language/Dutch.h | Bin 28782 -> 28896 bytes Language/English.h | Bin 27428 -> 27532 bytes Language/Finnish.h | Bin 28576 -> 28690 bytes Language/French.h | Bin 29518 -> 29626 bytes Language/German.h | Bin 29388 -> 29506 bytes Language/Greek.h | Bin 30052 -> 30118 bytes Language/Hebrew.h | Bin 26334 -> 26450 bytes Language/Hungarian.h | Bin 28788 -> 28896 bytes Language/Indonesian.h | 1 + Language/Italian.h | Bin 28742 -> 28854 bytes Language/Japanese.h | Bin 23708 -> 23804 bytes Language/Korean.h | Bin 23310 -> 23412 bytes Language/Latvian.h | Bin 27874 -> 27990 bytes Language/Lithuanian.h | Bin 28382 -> 28494 bytes Language/Malay.h | Bin 28234 -> 28346 bytes Language/NorwegianBokmal.h | Bin 27932 -> 28044 bytes Language/Polish.h | Bin 28030 -> 28144 bytes Language/PortugueseBrazil.h | Bin 28506 -> 28610 bytes Language/PortuguesePortugal.h | Bin 28696 -> 28824 bytes Language/Resource.rc | 1 + Language/Romanian.h | Bin 27992 -> 28096 bytes Language/Russian.h | Bin 28756 -> 28870 bytes Language/SerbianCyrillic.h | 1 + Language/SerbianLatin.h | 1 + Language/Slovak.h | Bin 28048 -> 28166 bytes Language/Slovenian.h | Bin 28630 -> 28738 bytes Language/SpanishModern.h | Bin 29218 -> 29338 bytes Language/Swedish.h | Bin 28050 -> 28162 bytes Language/Thai.h | Bin 26780 -> 26882 bytes Language/Turkish.h | Bin 28458 -> 28572 bytes Language/Ukrainian.h | Bin 28624 -> 28736 bytes Language/Vietnamese.h | Bin 27694 -> 27806 bytes Library/ContextMenu.cpp | 47 ++++++++++------------------------ Library/DialogManage.cpp | 4 +-- Library/Skin.cpp | 22 +++++++++++++--- Library/resource.h | 2 ++ 43 files changed, 41 insertions(+), 38 deletions(-) diff --git a/Language/Arabic.h b/Language/Arabic.h index 545f4325bbe4bd74f5db514891758d8f6dca66fa..269280a6684b1a305ccc4d996ef1eec5e21f8643 100644 GIT binary patch delta 38 wcmV+>0NMZi&;j((0kEbMlkgA(lb$aMlY~bmlW-0OlhiLDlSCpOv!)Z)R8qwc`~Uy| delta 14 Wcmexzk@3$3#tqAaH_M4!3jqK-y9W#a diff --git a/Language/Bulgarian.h b/Language/Bulgarian.h index 941c6a2b6ec951ff9391d0bb4717446dac6faa6c..94bb5eff0fa22ec332dd2393c216c787e7fca703 100644 GIT binary patch delta 50 zcmX?ck8#(1#tmU2oc;`c3?2;r3}KV&)%7PUh_LZmuqZItv)HjX0Vqa{&M|8wN!H diff --git a/Language/ChineseTraditional.h b/Language/ChineseTraditional.h index 72cdc22e6bc543dca510fbd0fa5d2d5f2461088e..a7f7a00e1607bcb199bd582b140d7f98ab509cb6 100644 GIT binary patch delta 38 wcmV+>0NMY@s{y2}0kB9BlMoLClbk9FlZF@^lkf}>1NdQFlkp)Rvq%wuL>F!jAOHXW delta 17 ZcmZ3ohVjH|#tj~VlY}@nuMwO~O>W>6nw(%LG5L#(+-4sUok#%j_6%JB delta 14 WcmaEHoAJjj#tl9qoA-$5L;?Uhh6b0NMYf)&Y#y0kG5)lMpZtllB`Nlkf)+lS(iUleTFdlQ0Vev)B_%S2M>BvH$=8 delta 18 acmeCV&bZ_n0NMYb-vN@~0kC2ela4VClT;@vlaK@ilgcp|lY|l=lim~tvuYGJTPKzd82|tP delta 18 acmbRAfN{Zn#tlg#ll??FHs293iv|Epa|cWS diff --git a/Language/French.h b/Language/French.h index f34328416f1f8c2acdcd02c3ab17a947c80bc16a..ecc71c6f692f9a39e9cfe027177f19b10a7cd5fc 100644 GIT binary patch delta 34 scmV+-0Nwx2<^j6r0kHlQlV&mwlcXamlh8H>lcX{blavG=v;GuNUKX7Ws{jB1 delta 14 Wcmdn>oblW<#tr{OHfM&NZ=d{;S$VUDD32V5#6f-4 K&6A8TIRXG|*%>YX delta 63 zcmV-F0KosI>jC8I0k9|)lMogNvz!$K9s!J#$rc|SvID^buLHvax&yTX!~?MdxdR{o VwFAHdtOLCR$&)cKA+yvo(m~>{7b5@w diff --git a/Language/Hebrew.h b/Language/Hebrew.h index eb48d0db57b2db90d85095d7fbee4cf99bad28e5..85a9e40d4dcced465f68c90fe45e56cc9a24949b 100644 GIT binary patch delta 34 scmV+-0NwxI%>mNR0kAF;ldvuhlPDA#lb{O{lj<%Ulg1z(vn~^`Q}~GuOaK4? delta 18 acmca~j`7}E#tnMHlLbULHm?$15exuMI|pe1 diff --git a/Language/Hungarian.h b/Language/Hungarian.h index 5230b880136eab14b72f543b16c79ba9d9303a58..c0b309fc78767a648c5c3132c0228cd91665b23a 100644 GIT binary patch delta 34 scmV+-0Nwxe-~r&_0kE7Dlh82^lY~qrlVAo0ldu&Olj3L~vz`>zTNwEdApigX delta 18 acmaFxknzg{#tm~sCKrfuY!(o`5DfrWj|dw8 diff --git a/Language/Indonesian.h b/Language/Indonesian.h index 6ccac5f20..5547d65ee 100644 --- a/Language/Indonesian.h +++ b/Language/Indonesian.h @@ -48,6 +48,7 @@ #define STR_XASPERCENTAGE "X sebagai persentase" #define STR_YASPERCENTAGE "Y sebagai persentase" #define STR_TRANSPARENCY "Transparansi" +#define STR_ONHOVER "Saat kursor berada diatas" #define STR_FADEIN "Efek muncul" #define STR_FADEOUT "Efek menghilang" #define STR_HIDEONMOUSEOVER "Sembunyikan saat kursor berada diatas" diff --git a/Language/Italian.h b/Language/Italian.h index 4c0b8011dc41c5cbaf6470cc1f2f9f08fbf3301a..2107234d4055858f0313dfeb6f070826c503a886 100644 GIT binary patch delta 34 scmV+-0Nww_-~qPb0kFyxljboFlNL7^lkgN4lkyc7lQd2qv&s~FTM;%6b^rhX delta 14 Wcmdn?knz|9#to-LHd~3-L<0agJqD)$ diff --git a/Language/Japanese.h b/Language/Japanese.h index aff434f4667fbe8739e626da31451e15745335f3..4a3931816ad5bdb6452ef47b30838d9fbfcc1485 100644 GIT binary patch delta 33 pcmbQUlkv|^#tl9~lb7l6O*Rphn&==f`JN8fWP>n;&3;0DUI5>g3+?~_ delta 18 acmeyflX1>Y#tl9~lLdr1Hg6H~@B#o!X$Ir~ diff --git a/Language/Korean.h b/Language/Korean.h index 8a631c59b12e069460882bfe90cf6a34e4a90417..7fb3a8e14be37629df0c31f97f66863de99cdc02 100644 GIT binary patch delta 36 scmeC%#`t9$;|2vGPJaeJ1`h^*hOo)+mGmd;=m<@jkYqFK0$YdocrOkFCJW&ApFAOvQ delta 18 acmdmWm+{mc#tl{?lQ&4QY+fhA69oWKvIlwq diff --git a/Language/NorwegianBokmal.h b/Language/NorwegianBokmal.h index ba1c3d269f0eb16656450038573f001582bbdd49..91b4b512135c8de4756cd2400d0e7daa2e8e8788 100644 GIT binary patch delta 32 ocmbPpi?Qc6;|39t$tMi>CO=Wsnq(+7c^kLf4;|39t$!|nB7Warm0surS2JZj> diff --git a/Language/Polish.h b/Language/Polish.h index a9b1050b5065a67ddf8189ce255cf1db64882685..6a0fd2491e1014967b46ba4178e017b582570e2e 100644 GIT binary patch delta 39 vcmex&i}Ay4#tkJRoc;`c3?2;r3}KV~)%7RYvQ6G#C^q?tfZXO15w1u8Ae0SD delta 14 WcmexxoAKW*#tkJRo1ckrMFIdkvsgUnyB37Jdrn103?SE%>V!Z delta 18 acmX?fpYhf`#tnHQlkG$~Hs2F@5(NNMfe2p! diff --git a/Language/PortuguesePortugal.h b/Language/PortuguesePortugal.h index c9bc4627d778b9e6b08c8d3d8edc80081681994c..df2019ccab1943afb74d1a386f399698d6bfa0a8 100644 GIT binary patch delta 38 wcmV+>0NMYT-~pK70kCQmlWs8%lNL4@laLe^ld3T$lg29^lb{O(vu+fsTO$AtSO5S3 delta 18 acmbR7ka5NX#tm5_lNWHaY0NMZ8+5y1Z0kB>alh6?alb$gOlT;)slW-OUlh!c~le85cvtAVXSUF!0K>z>% delta 18 acmX?boAJgi#tm^IlO04kHlGvu6afHI{Rlw- diff --git a/Language/Russian.h b/Language/Russian.h index 1b81c8eb016d21d68e70a8ffc7e46eda137668a1..41faf7ada5e6357a33e9ba1583c3015429573aff 100644 GIT binary patch delta 44 zcmccefbrNv#tlbAIQ<#?7(5vK8Nw#V%PLMzFcg{`XCyJ%Ohj(7o+!uWGa?<)09wrs AX#fBK delta 18 acmX^1knzd`#tlbACNB`>*lZ`-5e)!XI|v^D diff --git a/Language/SerbianCyrillic.h b/Language/SerbianCyrillic.h index 2f4b373f7..6a230e6bf 100644 --- a/Language/SerbianCyrillic.h +++ b/Language/SerbianCyrillic.h @@ -48,6 +48,7 @@ #define STR_XASPERCENTAGE "X као проценат" #define STR_YASPERCENTAGE "Y као проценат" #define STR_TRANSPARENCY "Прозирност" +#define STR_ONHOVER "При прелазу миша" #define STR_FADEIN "Постепено појављивање" #define STR_FADEOUT "Постепено нестајање" #define STR_HIDEONMOUSEOVER "Сакриј при преласку миша" diff --git a/Language/SerbianLatin.h b/Language/SerbianLatin.h index 7eafd6d8b..7569625fc 100644 --- a/Language/SerbianLatin.h +++ b/Language/SerbianLatin.h @@ -48,6 +48,7 @@ #define STR_XASPERCENTAGE "X kao procenat" #define STR_YASPERCENTAGE "Y kao procenat" #define STR_TRANSPARENCY "Prozirnost" +#define STR_ONHOVER "Pri prelazu miša" #define STR_FADEIN "Postepeno pojavljivanje" #define STR_FADEOUT "Postepeno nestajanje" #define STR_HIDEONMOUSEOVER "Sakrij pri prelasku miša" diff --git a/Language/Slovak.h b/Language/Slovak.h index 67514b6f73046a071aef399bc9d5859c286afd6b..1e41ee025978d54e2f52374c02ce613bda9cdd6b 100644 GIT binary patch delta 50 zcmbPmo3ZT<Quhn!HL>ZgPVZ%j5?lESsxD G#3BKqln^`s delta 14 VcmZp>!#LqK diff --git a/Language/Swedish.h b/Language/Swedish.h index 341b9f77c0c05824311e60b0daba155d4993e0e6..b55baeaf7c39f25f8db8a9d811fba43b927385bc 100644 GIT binary patch delta 42 zcmV+_0M-AJ+W~^y0kAq0lin~6lZHwrlMojMlOR0=lN>P=lg0}klb{p`vqBV5Sxm?d AF8}}l delta 18 acmZp=!#L?S;|42{$pWGrn>UFBL;?Us=LW6- diff --git a/Language/Thai.h b/Language/Thai.h index da048a79f06c40f30f20765f1e3a0a41cdf909ef..9990dfaafbc152f3a5f5f1482b0475b8e0bb7213 100644 GIT binary patch delta 66 zcmbPpk+JC#3V^ClL0P7wUWB>pF delta 31 ncmZp=#5m_7eAXNH_rRvkVac delta 14 WcmbPtlX2Y*#tm5_n{SC62?qc*mImqo diff --git a/Library/ContextMenu.cpp b/Library/ContextMenu.cpp index 00aff9bae..abb2786a4 100644 --- a/Library/ContextMenu.cpp +++ b/Library/ContextMenu.cpp @@ -314,17 +314,18 @@ HMENU ContextMenu::CreateSkinMenu(Skin* skin, int index, HMENU menu) MENU_ITEM(IDM_SKIN_TRANSPARENCY_70, ID_STR_70PERCENT), MENU_ITEM(IDM_SKIN_TRANSPARENCY_80, ID_STR_80PERCENT), MENU_ITEM(IDM_SKIN_TRANSPARENCY_90, ID_STR_90PERCENT), - MENU_ITEM(IDM_SKIN_TRANSPARENCY_100, ID_STR_100PERCENT), - MENU_SEPARATOR(), + MENU_ITEM(IDM_SKIN_TRANSPARENCY_100, ID_STR_100PERCENT)), + MENU_SUBMENU(ID_STR_ONHOVER, + MENU_ITEM(IDM_SKIN_HIDEONMOUSE_NONE, ID_STR_DONOTHING), + MENU_ITEM(IDM_SKIN_HIDEONMOUSE, ID_STR_HIDE), MENU_ITEM(IDM_SKIN_TRANSPARENCY_FADEIN, ID_STR_FADEIN), MENU_ITEM(IDM_SKIN_TRANSPARENCY_FADEOUT, ID_STR_FADEOUT)), MENU_SEPARATOR(), - MENU_ITEM(IDM_SKIN_HIDEONMOUSE, ID_STR_HIDEONMOUSEOVER), + MENU_ITEM(IDM_SKIN_CLICKTHROUGH, ID_STR_CLICKTHROUGH), MENU_ITEM(IDM_SKIN_DRAGGABLE, ID_STR_DRAGGABLE), + MENU_ITEM(IDM_SKIN_KEEPONSCREEN, ID_STR_KEEPONSCREEN), MENU_ITEM(IDM_SKIN_REMEMBERPOSITION, ID_STR_SAVEPOSITION), MENU_ITEM(IDM_SKIN_SNAPTOEDGES, ID_STR_SNAPTOEDGES), - MENU_ITEM(IDM_SKIN_CLICKTHROUGH, ID_STR_CLICKTHROUGH), - MENU_ITEM(IDM_SKIN_KEEPONSCREEN, ID_STR_KEEPONSCREEN), MENU_ITEM(IDM_SKIN_FAVORITE, ID_STR_FAVORITE)), MENU_SEPARATOR(), MENU_ITEM(IDM_SKIN_MANAGESKIN, ID_STR_MANAGESKIN), @@ -375,39 +376,19 @@ HMENU ContextMenu::CreateSkinMenu(Skin* skin, int index, HMENU menu) checkPos = max(0, checkPos); CheckMenuRadioItem(alphaMenu, checkPos, checkPos, checkPos, MF_BYPOSITION); } - - switch (skin->GetWindowHide()) - { - case HIDEMODE_FADEIN: - CheckMenuItem(alphaMenu, IDM_SKIN_TRANSPARENCY_FADEIN, MF_BYCOMMAND | MF_CHECKED); - EnableMenuItem(alphaMenu, IDM_SKIN_TRANSPARENCY_FADEOUT, MF_BYCOMMAND | MF_GRAYED); - break; - - case HIDEMODE_FADEOUT: - CheckMenuItem(alphaMenu, IDM_SKIN_TRANSPARENCY_FADEOUT, MF_BYCOMMAND | MF_CHECKED); - EnableMenuItem(alphaMenu, IDM_SKIN_TRANSPARENCY_FADEIN, MF_BYCOMMAND | MF_GRAYED); - break; - - case HIDEMODE_HIDE: - EnableMenuItem(alphaMenu, IDM_SKIN_TRANSPARENCY_FADEIN, MF_BYCOMMAND | MF_GRAYED); - EnableMenuItem(alphaMenu, IDM_SKIN_TRANSPARENCY_FADEOUT, MF_BYCOMMAND | MF_GRAYED); - break; - } } - // Tick the settings - switch (skin->GetWindowHide()) + // Tick the mouse over options (On hover) + HMENU hoverMenu = GetSubMenu(settingsMenu, 2); + if (hoverMenu) { - case HIDEMODE_HIDE: - CheckMenuItem(settingsMenu, IDM_SKIN_HIDEONMOUSE, MF_BYCOMMAND | MF_CHECKED); - break; - - case HIDEMODE_FADEIN: - case HIDEMODE_FADEOUT: - EnableMenuItem(settingsMenu, IDM_SKIN_HIDEONMOUSE, MF_BYCOMMAND | MF_GRAYED); - break; + int mode = skin->GetWindowHide(); + mode = min(3, mode); + mode = max(0, mode); + CheckMenuRadioItem(hoverMenu, mode, mode, mode, MF_BYPOSITION); } + // Tick the settings if (skin->GetSnapEdges()) { CheckMenuItem(settingsMenu, IDM_SKIN_SNAPTOEDGES, MF_BYCOMMAND | MF_CHECKED); diff --git a/Library/DialogManage.cpp b/Library/DialogManage.cpp index fbd5d186b..76c3c3e8b 100644 --- a/Library/DialogManage.cpp +++ b/Library/DialogManage.cpp @@ -539,10 +539,10 @@ void DialogManage::TabSkins::Create(HWND owner) CT_BUTTON(Id_DisplayMonitorButton, ID_STR_DISPLAYMONITOR, 359, 165, 119, 14, WS_VISIBLE | WS_TABSTOP | WS_DISABLED, 0), - CT_CHECKBOX(Id_DraggableCheckBox, ID_STR_DRAGGABLE, + CT_CHECKBOX(Id_ClickThroughCheckBox, ID_STR_CLICKTHROUGH, 360, 185, 118, 9, WS_VISIBLE | WS_TABSTOP | WS_DISABLED, 0), - CT_CHECKBOX(Id_ClickThroughCheckBox, ID_STR_CLICKTHROUGH, + CT_CHECKBOX(Id_DraggableCheckBox, ID_STR_DRAGGABLE, 360, 198, 118, 9, WS_VISIBLE | WS_TABSTOP | WS_DISABLED, 0), CT_CHECKBOX(Id_KeepOnScreenCheckBox, ID_STR_KEEPONSCREEN, diff --git a/Library/Skin.cpp b/Library/Skin.cpp index 8cbabdcb1..9312c1a98 100644 --- a/Library/Skin.cpp +++ b/Library/Skin.cpp @@ -3869,16 +3869,32 @@ LRESULT Skin::OnCommand(UINT uMsg, WPARAM wParam, LPARAM lParam) } break; + case IDM_SKIN_HIDEONMOUSE_NONE: + if (m_WindowHide != HIDEMODE_NONE) + { + SetWindowHide(HIDEMODE_NONE); + } + break; + case IDM_SKIN_HIDEONMOUSE: - SetWindowHide((m_WindowHide == HIDEMODE_NONE) ? HIDEMODE_HIDE : HIDEMODE_NONE); + if (m_WindowHide != HIDEMODE_HIDE) + { + SetWindowHide(HIDEMODE_HIDE); + } break; case IDM_SKIN_TRANSPARENCY_FADEIN: - SetWindowHide((m_WindowHide == HIDEMODE_NONE) ? HIDEMODE_FADEIN : HIDEMODE_NONE); + if (m_WindowHide != HIDEMODE_FADEIN) + { + SetWindowHide(HIDEMODE_FADEIN); + } break; case IDM_SKIN_TRANSPARENCY_FADEOUT: - SetWindowHide((m_WindowHide == HIDEMODE_NONE) ? HIDEMODE_FADEOUT : HIDEMODE_NONE); + if (m_WindowHide != HIDEMODE_FADEOUT) + { + SetWindowHide(HIDEMODE_FADEOUT); + } break; case IDM_SKIN_REMEMBERPOSITION: diff --git a/Library/resource.h b/Library/resource.h index 4fd01678c..0927fd357 100644 --- a/Library/resource.h +++ b/Library/resource.h @@ -244,6 +244,7 @@ #define ID_STR_AUTOMATICUPDATE 2160 #define ID_STR_INSTALL_NEW_VERSION 2161 #define ID_STR_CLICK_TO_INSTALL 2162 +#define ID_STR_ONHOVER 2163 #define ID_STR_GAMEMODE 2800 #define ID_STR_GAMEMODE_START 2801 @@ -360,6 +361,7 @@ #define IDM_GAMEMODE_FULLSCREEN 4078 #define IDM_GAMEMODE_PROCESSLIST 4079 #define IDM_INSTALL_NEW_VERSION 4080 +#define IDM_SKIN_HIDEONMOUSE_NONE 4081 #define IDM_SKIN_CUSTOMCONTEXTMENU_FIRST 9000 #define IDM_SKIN_CUSTOMCONTEXTMENU_LAST 9024