From d0ff83e58ace7ee9dd35a39af2ab5a5bb3437b44 Mon Sep 17 00:00:00 2001 From: martii Date: Sat, 28 Dec 2013 22:45:29 +0100 Subject: [PATCH] guimoviebrowser: start bookmark: query actual item position instead of using fixed value Origin commit data ------------------ Commit: https://github.com/neutrino-images/ni-neutrino/commit/126a2ffde25b4738851bd4e490ab5f9ce2265ef8 Author: martii Date: 2013-12-28 (Sat, 28 Dec 2013) --- src/gui/moviebrowser.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gui/moviebrowser.cpp b/src/gui/moviebrowser.cpp index 8de218c21..8aae50b94 100644 --- a/src/gui/moviebrowser.cpp +++ b/src/gui/moviebrowser.cpp @@ -3349,6 +3349,8 @@ int CMovieBrowser::showStartPosSelectionMenu(void) // P2 startPosSelectionMenu.addIntroItems(LOCALE_MOVIEBROWSER_START_HEAD, NONEXISTANT_LOCALE, CMenuWidget::BTN_TYPE_CANCEL); + int off = startPosSelectionMenu.getItemsCount(); + if(m_movieSelectionHandler->bookmarks.start != 0) { startPosSelectionMenu.addItem(new CMenuForwarder(LOCALE_MOVIEBROWSER_BOOK_MOVIESTART, true, start_pos)); @@ -3381,7 +3383,7 @@ int CMovieBrowser::showStartPosSelectionMenu(void) // P2 startPosSelectionMenu.exec(NULL, "12345"); /* check what menu item was ok'd and set the appropriate play offset*/ result = startPosSelectionMenu.getSelectedLine(); - result -= 4; // sub-text, separator, back, separator-line + result -= off; // sub-text, separator, back, separator-line if(result >= 0 && result <= MAX_NUMBER_OF_BOOKMARK_ITEMS) {