moviebrowser: add switch for cut of text inside rows, default enabled

Origin commit data
------------------
Branch: ni/coolstream
Commit: 52f85ed3d0
Author: Thilo Graf <dbt@novatux.de>
Date: 2019-05-05 (Sun, 05 May 2019)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
2019-05-05 16:00:00 +02:00
committed by vanhofen
parent 0c52628059
commit fcd10f6302
4 changed files with 11 additions and 0 deletions

View File

@@ -470,6 +470,7 @@ void CMovieBrowser::initGlobalSettings(void)
/***** Browser List **************/
m_settings.browserFrameHeight = 65; /* percent */
m_settings.browserCutLongRowText = 1;
m_settings.browserRowNr = 6;
m_settings.browserRowItem[0] = MB_INFO_TITLE;
@@ -655,6 +656,7 @@ bool CMovieBrowser::loadSettings(MB_SETTINGS* settings)
}
/* these variables are used for the listframes */
settings->browserFrameHeight = configfile.getInt32("mb_browserFrameHeight", 50);
settings->browserCutLongRowText = configfile.getInt32("mb_browserCutLongRowText", 1);
settings->browserRowNr = configfile.getInt32("mb_browserRowNr", 0);
for (int i = 0; i < MB_MAX_ROWS && i < settings->browserRowNr; i++)
{
@@ -722,6 +724,8 @@ bool CMovieBrowser::saveSettings(MB_SETTINGS* settings)
}
/* these variables are used for the listframes */
configfile.setInt32("mb_browserFrameHeight", settings->browserFrameHeight);
configfile.setInt32("mb_browserCutLongRowText", settings->browserCutLongRowText);
configfile.setInt32("mb_browserRowNr",settings->browserRowNr);
for (int i = 0; i < MB_MAX_ROWS && i < settings->browserRowNr; i++)
{
@@ -1816,6 +1820,7 @@ void CMovieBrowser::refreshLastPlayList(void) //P2
m_playListLines.marked.push_back(m_vHandlePlayList[handle]->marked);
}
m_pcLastPlay->setLines(&m_playListLines);
m_pcLastPlay->cutRowText(&m_settings.browserCutLongRowText);
m_currentPlaySelection = m_pcLastPlay->getSelectedLine();
// update selected movie if browser is in the focus
@@ -1874,6 +1879,7 @@ void CMovieBrowser::refreshLastRecordList(void) //P2
}
m_pcLastRecord->setLines(&m_recordListLines);
m_pcLastRecord->cutRowText(&m_settings.browserCutLongRowText);
m_currentRecordSelection = m_pcLastRecord->getSelectedLine();
// update selected movie if browser is in the focus
@@ -1969,6 +1975,7 @@ void CMovieBrowser::refreshBrowserList(void) //P1
m_browserListLines.marked.push_back(m_vHandleBrowserList[handle]->marked);
}
m_pcBrowser->setLines(&m_browserListLines);
m_pcBrowser->cutRowText(&m_settings.browserCutLongRowText);
m_currentBrowserSelection = m_pcBrowser->getSelectedLine();
// update selected movie if browser is in the focus
@@ -3575,6 +3582,7 @@ bool CMovieBrowser::showMenu(bool calledExternally)
optionsMenuBrowser.addItem(new CMenuForwarder(LOCALE_MOVIEBROWSER_LAST_RECORD_MAX_ITEMS, true, recMaxUserIntInput.getValue(), &recMaxUserIntInput));
optionsMenuBrowser.addItem(new CMenuForwarder(LOCALE_MOVIEBROWSER_BROWSER_FRAME_HIGH, true, browserFrameUserIntInput.getValue(), &browserFrameUserIntInput));
optionsMenuBrowser.addItem(new CMenuOptionChooser(LOCALE_MOVIEBROWSER_BROWSER_ADDITIONAL, (int*)(&m_settings.browserAdditional), MESSAGEBOX_NO_YES_OPTIONS, MESSAGEBOX_NO_YES_OPTION_COUNT, true));
optionsMenuBrowser.addItem(new CMenuOptionChooser(LOCALE_MOVIEBROWSER_BROWSER_CUT_LONG_ROWTEXT, (int*)(&m_settings.browserCutLongRowText), MESSAGEBOX_NO_YES_OPTIONS, MESSAGEBOX_NO_YES_OPTION_COUNT, true));
optionsMenuBrowser.addItem(new CMenuSeparator(CMenuSeparator::LINE | CMenuSeparator::STRING, LOCALE_MOVIEBROWSER_BROWSER_ROW_HEAD));
optionsMenuBrowser.addItem(new CMenuForwarder(LOCALE_MOVIEBROWSER_BROWSER_ROW_NR, true, browserRowNrIntInput.getValue(), &browserRowNrIntInput));
optionsMenuBrowser.addItem(GenericMenuSeparator);