From fb530563908192710e111786f636da2ebccb7924 Mon Sep 17 00:00:00 2001 From: MikalaiR Date: Tue, 29 Sep 2015 16:06:00 +0000 Subject: SmileyAdd: horizontal sorting id default git-svn-id: http://svn.miranda-ng.org/main/trunk@15474 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/SmileyAdd/src/options.cpp | 2 +- plugins/SmileyAdd/src/smltool.cpp | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) (limited to 'plugins') diff --git a/plugins/SmileyAdd/src/options.cpp b/plugins/SmileyAdd/src/options.cpp index f75931b937..4d82090033 100644 --- a/plugins/SmileyAdd/src/options.cpp +++ b/plugins/SmileyAdd/src/options.cpp @@ -641,7 +641,7 @@ void OptionsType::Load(void) SelWndBkgClr = db_get_dw(NULL, "SmileyAdd", "SelWndBkgClr", GetSysColor(COLOR_WINDOW)); MaxCustomSmileySize = db_get_dw(NULL, "SmileyAdd", "MaxCustomSmileySize", 0); MinSmileySize = db_get_dw(NULL, "SmileyAdd", "MinSmileySize", 0); - HorizontalSorting = db_get_b(NULL, "SmileyAdd", "HorizontalSorting") != 0; + HorizontalSorting = db_get_b(NULL, "SmileyAdd", "HorizontalSorting", 1) != 0; } diff --git a/plugins/SmileyAdd/src/smltool.cpp b/plugins/SmileyAdd/src/smltool.cpp index 15ff7b0497..a4a2e41d22 100644 --- a/plugins/SmileyAdd/src/smltool.cpp +++ b/plugins/SmileyAdd/src/smltool.cpp @@ -350,19 +350,19 @@ void SmileyToolWindowType::KeyUp(WPARAM wParam, LPARAM lParam) break; case VK_LEFT: - but -= (opt.IEViewStyle ? 1 : m_NumberOfVerticalButtons) * LOWORD(lParam); + but -= (opt.HorizontalSorting ? 1 : m_NumberOfVerticalButtons) * LOWORD(lParam); break; case VK_UP: - but -= (opt.IEViewStyle ? m_NumberOfHorizontalButtons : 1) * LOWORD(lParam); + but -= (opt.HorizontalSorting ? m_NumberOfHorizontalButtons : 1) * LOWORD(lParam); break; case VK_RIGHT: - but += (opt.IEViewStyle ? 1 : m_NumberOfVerticalButtons) * LOWORD(lParam); + but += (opt.HorizontalSorting ? 1 : m_NumberOfVerticalButtons) * LOWORD(lParam); break; case VK_DOWN: - but += (opt.IEViewStyle ? m_NumberOfHorizontalButtons : 1) * LOWORD(lParam); + but += (opt.HorizontalSorting ? m_NumberOfHorizontalButtons : 1) * LOWORD(lParam); break; case VK_SPACE: @@ -412,11 +412,11 @@ void SmileyToolWindowType::KeyUp(WPARAM wParam, LPARAM lParam) if (numKey != -1) { if (rowSel == -1) { rowSel = numKey; - but = (opt.IEViewStyle ? m_NumberOfHorizontalButtons : 1) * rowSel; + but = (opt.HorizontalSorting ? m_NumberOfHorizontalButtons : 1) * rowSel; } else { colSel = numKey; - if (opt.IEViewStyle) + if (opt.HorizontalSorting) but = colSel + m_NumberOfHorizontalButtons * rowSel; else but = rowSel + m_NumberOfVerticalButtons * colSel; -- cgit v1.2.3