Skip to content

Commit

Permalink
3.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
henrypp committed Feb 9, 2018
1 parent 8bb88c3 commit 90976cd
Show file tree
Hide file tree
Showing 31 changed files with 187 additions and 131 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
v3.3.2 (9 February 2018)
- revert "start minimized" option (issue #39)
- updated project sdk
- cosmetic fixes

v3.3.1 (5 January 2018)
- disable auto-reduct by default
- updated translations
Expand Down
5 changes: 5 additions & 0 deletions bin/History.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
v3.3.2 (9 February 2018)
- revert "start minimized" option (issue #39)
- updated project sdk
- cosmetic fixes

v3.3.1 (5 January 2018)
- disable auto-reduct by default
- updated translations
Expand Down
Binary file modified bin/i18n/!example.txt
Binary file not shown.
Binary file modified bin/i18n/Bulgarian.ini
Binary file not shown.
Binary file modified bin/i18n/Chinese (Simplified).ini
Binary file not shown.
Binary file modified bin/i18n/Chinese (Simplified2).ini
Binary file not shown.
Binary file modified bin/i18n/Chinese (Traditional).ini
Binary file not shown.
Binary file modified bin/i18n/French.ini
Binary file not shown.
Binary file modified bin/i18n/German.ini
Binary file not shown.
Binary file modified bin/i18n/Hungarian.ini
Binary file not shown.
Binary file modified bin/i18n/Indonesian.ini
Binary file not shown.
Binary file modified bin/i18n/Italiano.ini
Binary file not shown.
Binary file modified bin/i18n/Korean.ini
Binary file not shown.
Binary file modified bin/i18n/Persian.ini
Binary file not shown.
Binary file modified bin/i18n/Polski.ini
Binary file not shown.
Binary file modified bin/i18n/Portuguese (Brazil).ini
Binary file not shown.
Binary file modified bin/i18n/Portuguese.ini
Binary file not shown.
Binary file modified bin/i18n/Russian.ini
Binary file not shown.
Binary file modified bin/i18n/Spanish.ini
Binary file not shown.
Binary file modified bin/i18n/Spanish2.ini
Binary file not shown.
Binary file modified bin/i18n/Spanish3.ini
Binary file not shown.
Binary file modified bin/i18n/Swedish.ini
Binary file not shown.
Binary file modified bin/i18n/Turkish.ini
Binary file not shown.
Binary file modified bin/i18n/Ukrainian.ini
Binary file not shown.
Binary file modified bin/memreduct.lng
Binary file not shown.
8 changes: 4 additions & 4 deletions memreduct.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@
<ExceptionHandling>Sync</ExceptionHandling>
<ControlFlowGuard>Guard</ControlFlowGuard>
<FunctionLevelLinking>true</FunctionLevelLinking>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_SETTINGS;_APP_HAVE_UPDATES;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>
</MinimalRebuild>
<OmitFramePointers>true</OmitFramePointers>
Expand Down Expand Up @@ -172,7 +172,7 @@
<ExceptionHandling>Sync</ExceptionHandling>
<ControlFlowGuard>Guard</ControlFlowGuard>
<FunctionLevelLinking>true</FunctionLevelLinking>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_SETTINGS;_APP_HAVE_UPDATES;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>
</MinimalRebuild>
<OmitFramePointers>true</OmitFramePointers>
Expand Down Expand Up @@ -219,7 +219,7 @@
<MinimalRebuild>
</MinimalRebuild>
<DebugInformationFormat>None</DebugInformationFormat>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_SETTINGS;_APP_HAVE_UPDATES;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<OmitFramePointers>true</OmitFramePointers>
<EnableParallelCodeGeneration>
</EnableParallelCodeGeneration>
Expand Down Expand Up @@ -265,7 +265,7 @@
<MinimalRebuild>
</MinimalRebuild>
<DebugInformationFormat>None</DebugInformationFormat>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_UNICODE;UNICODE;_APP_HAVE_SETTINGS;_APP_HAVE_UPDATES;_APP_HAVE_NTDLL;_APP_HAVE_AUTORUN;_APP_HAVE_SKIPUAC;_APP_HAVE_TRAY;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<EnableParallelCodeGeneration>
</EnableParallelCodeGeneration>
<BufferSecurityCheck>false</BufferSecurityCheck>
Expand Down
6 changes: 3 additions & 3 deletions src/app.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

#define APP_NAME L"Mem Reduct"
#define APP_NAME_SHORT L"memreduct"
#define APP_VERSION L"3.3.1"
#define APP_VERSION_RES 3,3,1,0
#define APP_COPYRIGHT L"(c) 2011-2018 " _APP_AUTHOR L". All Rights Reserved."
#define APP_VERSION L"3.3.2"
#define APP_VERSION_RES 3,3,2,0
#define APP_COPYRIGHT L"(c) 2011-2018 " _APP_AUTHOR L". All Rights Reversed."

#endif // __APP_H__
60 changes: 48 additions & 12 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -297,14 +297,7 @@ HICON _app_iconcreate ()
}
else
{
if (has_danger)
{
color = app.ConfigGet (L"TrayColorDanger", TRAY_COLOR_DANGER).AsUlong ();
}
else
{
color = app.ConfigGet (L"TrayColorWarning", TRAY_COLOR_WARNING).AsUlong ();
}
color = has_danger ? app.ConfigGet (L"TrayColorDanger", TRAY_COLOR_DANGER).AsUlong () : app.ConfigGet (L"TrayColorWarning", TRAY_COLOR_WARNING).AsUlong ();
}
}

Expand Down Expand Up @@ -580,6 +573,9 @@ BOOL initializer_callback (HWND hwnd, DWORD msg, LPVOID, LPVOID)

// configure menu
CheckMenuItem (GetMenu (hwnd), IDM_ALWAYSONTOP_CHK, MF_BYCOMMAND | (app.ConfigGet (L"AlwaysOnTop", false).AsBool () ? MF_CHECKED : MF_UNCHECKED));
CheckMenuItem (GetMenu (hwnd), IDM_LOADONSTARTUP_CHK, MF_BYCOMMAND | (app.AutorunIsEnabled () ? MF_CHECKED : MF_UNCHECKED));
CheckMenuItem (GetMenu (hwnd), IDM_STARTMINIMIZED_CHK, MF_BYCOMMAND | (app.ConfigGet (L"IsStartMinimized", false).AsBool () ? MF_CHECKED : MF_UNCHECKED));
CheckMenuItem (GetMenu (hwnd), IDM_REDUCTCONFIRMATION_CHK, MF_BYCOMMAND | (app.ConfigGet (L"IsShowReductConfirmation", true).AsBool () ? MF_CHECKED : MF_UNCHECKED));
CheckMenuItem (GetMenu (hwnd), IDM_CHECKUPDATES_CHK, MF_BYCOMMAND | (app.ConfigGet (L"CheckUpdates", true).AsBool () ? MF_CHECKED : MF_UNCHECKED));

break;
Expand All @@ -595,8 +591,11 @@ BOOL initializer_callback (HWND hwnd, DWORD msg, LPVOID, LPVOID)
app.LocaleMenu (menu, IDS_EXIT, IDM_EXIT, false, nullptr);
app.LocaleMenu (menu, IDS_SETTINGS, 1, true, nullptr);
app.LocaleMenu (menu, IDS_ALWAYSONTOP_CHK, IDM_ALWAYSONTOP_CHK, false, nullptr);
app.LocaleMenu (menu, IDS_LOADONSTARTUP_CHK, IDM_LOADONSTARTUP_CHK, false, nullptr);
app.LocaleMenu (menu, IDS_STARTMINIMIZED_CHK, IDM_STARTMINIMIZED_CHK, false, nullptr);
app.LocaleMenu (menu, IDS_REDUCTCONFIRMATION_CHK, IDM_REDUCTCONFIRMATION_CHK, false, nullptr);
app.LocaleMenu (menu, IDS_CHECKUPDATES_CHK, IDM_CHECKUPDATES_CHK, false, nullptr);
app.LocaleMenu (GetSubMenu (menu, 1), IDS_LANGUAGE, 3, true, L" (Language)");
app.LocaleMenu (GetSubMenu (menu, 1), IDS_LANGUAGE, LANG_MENU, true, L" (Language)");
app.LocaleMenu (menu, IDS_HELP, 2, true, nullptr);
app.LocaleMenu (menu, IDS_WEBSITE, IDM_WEBSITE, false, nullptr);
app.LocaleMenu (menu, IDS_CHECKUPDATES, IDM_CHECKUPDATES, false, nullptr);
Expand Down Expand Up @@ -656,6 +655,7 @@ BOOL settings_callback (HWND hwnd, DWORD msg, LPVOID lpdata1, LPVOID lpdata2)
CheckDlgButton (hwnd, IDC_LOADONSTARTUP_CHK, app.AutorunIsEnabled () ? BST_CHECKED : BST_UNCHECKED);
#endif // _APP_HAVE_AUTORUN

CheckDlgButton (hwnd, IDC_STARTMINIMIZED_CHK, app.ConfigGet (L"IsStartMinimized", false).AsBool () ? BST_CHECKED : BST_UNCHECKED);
CheckDlgButton (hwnd, IDC_REDUCTCONFIRMATION_CHK, app.ConfigGet (L"IsShowReductConfirmation", true).AsBool () ? BST_CHECKED : BST_UNCHECKED);

#ifdef _APP_HAVE_SKIPUAC
Expand Down Expand Up @@ -783,6 +783,7 @@ BOOL settings_callback (HWND hwnd, DWORD msg, LPVOID lpdata1, LPVOID lpdata2)
{
SetDlgItemText (hwnd, IDC_ALWAYSONTOP_CHK, app.LocaleString (IDS_ALWAYSONTOP_CHK, nullptr));
SetDlgItemText (hwnd, IDC_LOADONSTARTUP_CHK, app.LocaleString (IDS_LOADONSTARTUP_CHK, nullptr));
SetDlgItemText (hwnd, IDC_STARTMINIMIZED_CHK, app.LocaleString (IDS_STARTMINIMIZED_CHK, nullptr));
SetDlgItemText (hwnd, IDC_REDUCTCONFIRMATION_CHK, app.LocaleString (IDS_REDUCTCONFIRMATION_CHK, nullptr));
SetDlgItemText (hwnd, IDC_SKIPUACWARNING_CHK, app.LocaleString (IDS_SKIPUACWARNING_CHK, nullptr));
SetDlgItemText (hwnd, IDC_CHECKUPDATES_CHK, app.LocaleString (IDS_CHECKUPDATES_CHK, nullptr));
Expand Down Expand Up @@ -988,8 +989,9 @@ BOOL settings_callback (HWND hwnd, DWORD msg, LPVOID lpdata1, LPVOID lpdata2)
}

case IDC_ALWAYSONTOP_CHK:
case IDC_REDUCTCONFIRMATION_CHK:
case IDC_LOADONSTARTUP_CHK:
case IDC_STARTMINIMIZED_CHK:
case IDC_REDUCTCONFIRMATION_CHK:
case IDC_SKIPUACWARNING_CHK:
case IDC_CHECKUPDATES_CHK:
case IDC_LANGUAGE:
Expand Down Expand Up @@ -1021,6 +1023,10 @@ BOOL settings_callback (HWND hwnd, DWORD msg, LPVOID lpdata1, LPVOID lpdata2)
app.ConfigSet (L"AlwaysOnTop", (IsDlgButtonChecked (hwnd, ctrl_id) == BST_CHECKED) ? true : false);
CheckMenuItem (GetMenu (app.GetHWND ()), IDM_ALWAYSONTOP_CHK, MF_BYCOMMAND | ((IsDlgButtonChecked (hwnd, ctrl_id) == BST_CHECKED) ? MF_CHECKED : MF_UNCHECKED));
}
else if (ctrl_id == IDC_STARTMINIMIZED_CHK && notify_code == BN_CLICKED)
{
app.ConfigSet (L"IsStartMinimized", (IsDlgButtonChecked (hwnd, ctrl_id) == BST_CHECKED) ? true : false);
}
else if (ctrl_id == IDC_REDUCTCONFIRMATION_CHK && notify_code == BN_CLICKED)
{
app.ConfigSet (L"IsShowReductConfirmation", (IsDlgButtonChecked (hwnd, ctrl_id) == BST_CHECKED) ? true : false);
Expand Down Expand Up @@ -1576,19 +1582,49 @@ INT_PTR CALLBACK DlgProc (HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam)
{
const bool new_val = !app.ConfigGet (L"AlwaysOnTop", false).AsBool ();

CheckMenuItem (GetMenu (hwnd), IDM_ALWAYSONTOP_CHK, MF_BYCOMMAND | (new_val ? MF_CHECKED : MF_UNCHECKED));
CheckMenuItem (GetMenu (hwnd), LOWORD (wparam), MF_BYCOMMAND | (new_val ? MF_CHECKED : MF_UNCHECKED));
app.ConfigSet (L"AlwaysOnTop", new_val);

_r_wnd_top (hwnd, new_val);

break;
}

case IDM_STARTMINIMIZED_CHK:
{
const bool new_val = !app.ConfigGet (L"IsStartMinimized", false).AsBool ();

CheckMenuItem (GetMenu (hwnd), LOWORD (wparam), MF_BYCOMMAND | (new_val ? MF_CHECKED : MF_UNCHECKED));
app.ConfigSet (L"IsStartMinimized", new_val);

break;
}

case IDM_REDUCTCONFIRMATION_CHK:
{
const bool new_val = !app.ConfigGet (L"IsShowReductConfirmation", true).AsBool ();

CheckMenuItem (GetMenu (hwnd), LOWORD (wparam), MF_BYCOMMAND | (new_val ? MF_CHECKED : MF_UNCHECKED));
app.ConfigSet (L"IsShowReductConfirmation", new_val);

break;
}

case IDM_LOADONSTARTUP_CHK:
{
const bool new_val = !app.AutorunIsEnabled ();

app.AutorunEnable (new_val);
CheckMenuItem (GetMenu (hwnd), LOWORD (wparam), MF_BYCOMMAND | (new_val ? MF_CHECKED : MF_UNCHECKED));

break;
}

case IDM_CHECKUPDATES_CHK:
{
const bool new_val = !app.ConfigGet (L"CheckUpdates", true).AsBool ();

CheckMenuItem (GetMenu (hwnd), IDM_CHECKUPDATES_CHK, MF_BYCOMMAND | (new_val ? MF_CHECKED : MF_UNCHECKED));
CheckMenuItem (GetMenu (hwnd), LOWORD (wparam), MF_BYCOMMAND | (new_val ? MF_CHECKED : MF_UNCHECKED));
app.ConfigSet (L"CheckUpdates", new_val);

break;
Expand Down
2 changes: 1 addition & 1 deletion src/main.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#define FONT_DEFAULT L"Tahoma;8;400"
#define TIMER 1000
#define UID 1337
#define LANG_MENU 3
#define LANG_MENU 6

// libs
#pragma comment(lib, "ntdll.lib")
Expand Down
Loading

0 comments on commit 90976cd

Please sign in to comment.