[mythtv] Re: [PATCH] : mythmusic: compile error in
databasebox.cpp due to lcd update
Ben de Luca
bend at bedel.mine.nu
Mon Oct 25 03:35:04 UTC 2004
Is this fixed? I still cant get it to build, thats including the
change from this morning.
On 25/10/2004, at 8:45 AM, Kenneth Aafløy wrote:
> On Monday 25 October 2004 00:17, J. Donavan Stanley wrote:
>> Kenneth Aafløy wrote:
>>> On Sunday 24 October 2004 23:36, Stefan Frank wrote:
>>>> I _believe_ Kenneth forgot to send a patch for databasebox.cpp
>>>> similar
>>>> to playbackbox.cpp. The attached patch makes mythmusic compile for
>>>> me
>>>> (against latest cvs). I got the same make error before.
>>>>
>>>> Kenneth, please have a look at the patch as i don't use a lcd
>>>> device.
>>>
>>> I just checked the patch I sent and it contains the required changes
>>> for
>>> databasebox.cpp, I have not had a chance to even compile my plugins
>>> after
>>> the patch got in, but my guess is that this was just not comitted.
>>> Sorry
>>> about assuming the fault was yours, Jack.
>>
>> All modules that use LCD code have been updated and checked in AFAIK.
>> I'm able to compile all of them here, and I fixed the ones that were
>> left out of the LCD patch and check them in as well.
>
> http://cvs.mythtv.org/cgi-bin/viewcvs.cgi/mythmusic/mythmusic/
> databasebox.cpp
>
> Does not look like it to me, as my patch started out with:
>
> Index: mythmusic/databasebox.cpp
> ===================================================================
> RCS file: /var/lib/mythcvs/mythmusic/mythmusic/databasebox.cpp,v
> retrieving revision 1.37
> diff -u -u -r1.37 databasebox.cpp
> --- mythmusic/databasebox.cpp 25 May 2004 05:33:44 -0000 1.37
> +++ mythmusic/databasebox.cpp 23 Oct 2004 02:07:42 -0000
> @@ -147,7 +147,8 @@
>
> all_music->resetListings();
>
> - gContext->GetLCDDevice()->switchToTime();
> + if (class LCD * lcd = LCD::Get())
> + lcd->switchToTime();
>
> delete rootNode;
> }
> @@ -164,13 +165,16 @@
>
> QString a_string = tr("All My Music ~ Loading Music Data ");
>
> - // Set Loading Message on the LCD
> - QPtrList<LCDTextItem> textItems;
> - textItems.setAutoDelete(true);
> -
> - textItems.append(new LCDTextItem(1, ALIGN_CENTERED,
> - tr("Loading Music Data"), "Generic", false));
> - gContext->GetLCDDevice()->switchToGeneric(&textItems);
> + if (class LCD * lcd = LCD::Get())
> + {
> + // Set Loading Message on the LCD
> + QPtrList<LCDTextItem> textItems;
> + textItems.setAutoDelete(true);
> +
> + textItems.append(new LCDTextItem(1, ALIGN_CENTERED,
> + tr("Loading Music Data"), "Generic",
> false));
> + lcd->switchToGeneric(&textItems);
> + }
>
> for (int i = 0; i < numb_wait_dots; i++)
> a_string += ".";
> @@ -1298,6 +1302,10 @@
>
> void DatabaseBox::updateLCDMenu(QKeyEvent * e)
> {
> + class LCD * lcd = LCD::Get();
> + if (lcd == NULL)
> + return;
> +
> // Update the LCD with a menu of items
> UIListGenericTree *curItem = tree->GetCurrentPosition();
>
> @@ -1317,14 +1325,14 @@
> buildMenuTree(menuItems, item_ptr, 1);
>
> if (!menuItems->isEmpty())
> - gContext->GetLCDDevice()->switchToMenu(menuItems, "MythMusic",
> false);
> + lcd->switchToMenu(menuItems, "MythMusic", false);
>
> //release the container
> delete menuItems;
>
> //Were done, so switch back to the time display
> if (e->key() == Key_Escape)
> - gContext->GetLCDDevice()->switchToTime();
> + lcd->switchToTime();
> }
>
> LCDMenuItem *DatabaseBox::buildLCDMenuItem(TreeCheckItem *item_ptr,
> _______________________________________________
> mythtv-dev mailing list
> mythtv-dev at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev
>
More information about the mythtv-dev
mailing list