diff options
author | George Hazan <ghazan@miranda.im> | 2020-07-28 14:13:07 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2020-07-28 14:13:07 +0300 |
commit | 841393dcb0392491efe99f4682130757fd45dd9c (patch) | |
tree | b40e773763cfbee98f647b1f2cd5bb89cf70433a /plugins | |
parent | c8252769733a7b8bd632ac2eb0fd909c0cb67d0f (diff) |
code cleaning
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/Clist_modern/src/modern_clcutils.cpp | 8 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_defsettings.h | 1 |
2 files changed, 3 insertions, 6 deletions
diff --git a/plugins/Clist_modern/src/modern_clcutils.cpp b/plugins/Clist_modern/src/modern_clcutils.cpp index e1e53497b8..22547bc4f5 100644 --- a/plugins/Clist_modern/src/modern_clcutils.cpp +++ b/plugins/Clist_modern/src/modern_clcutils.cpp @@ -476,8 +476,7 @@ void cli_LoadCLCOptions(HWND hwnd, ClcData *dat, BOOL bFirst) //TODO: Add to settings
dat->row_align_group_mode = g_plugin.getByte("AlignGroupCaptions", SETTING_ALIGNGROPCAPTION_DEFAULT);
if (g_clistApi.hwndContactTree == nullptr || dat->hWnd == g_clistApi.hwndContactTree) {
-
- int defItemsOrder[NUM_ITEM_TYPE] = SETTINS_ROWITEMORDER_DEFAULT;
+ int defItemsOrder[NUM_ITEM_TYPE] = { ITEM_AVATAR, ITEM_ICON, ITEM_TEXT, ITEM_CONTACT_TIME, ITEM_EXTRA_ICONS };
for (int i = 0; i < NUM_ITEM_TYPE; i++) {
char tmp[128];
mir_snprintf(tmp, "RowPos%d", i);
@@ -485,9 +484,8 @@ void cli_LoadCLCOptions(HWND hwnd, ClcData *dat, BOOL bFirst) }
}
else {
- int defItems[] = { ITEM_ICON, ITEM_TEXT, ITEM_EXTRA_ICONS, };
- for (int i = 0; i < NUM_ITEM_TYPE; i++)
- dat->row_items[i] = (i < _countof(defItems)) ? defItems[i] : -1;
+ int defItems[NUM_ITEM_TYPE] = { ITEM_ICON, ITEM_TEXT, ITEM_EXTRA_ICONS, -1, -1 };
+ memcpy(dat->row_items, defItems, sizeof(defItems));
}
// Avatar
diff --git a/plugins/Clist_modern/src/modern_defsettings.h b/plugins/Clist_modern/src/modern_defsettings.h index 72d9a87bea..b9de0e9246 100644 --- a/plugins/Clist_modern/src/modern_defsettings.h +++ b/plugins/Clist_modern/src/modern_defsettings.h @@ -142,7 +142,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #define SETTING_ALIGNRIGHTORIGHT_DEFAULT 1
#define SETTING_HIDEGROUPSICON_DEFAULT 0
#define SETTING_ALIGNGROPCAPTION_DEFAULT 0
-#define SETTINS_ROWITEMORDER_DEFAULT {ITEM_AVATAR, ITEM_ICON, ITEM_TEXT, ITEM_CONTACT_TIME, ITEM_EXTRA_ICONS}
#define SETTINGS_SHOWAVATARS_DEFAULT 0
#define SETTINGS_AVATARDRAWBORDER_DEFAULT 0
|