diff --git a/src/gui/bedit/bouqueteditor_bouquets.cpp b/src/gui/bedit/bouqueteditor_bouquets.cpp index 69ee284ab..430c467ee 100644 --- a/src/gui/bedit/bouqueteditor_bouquets.cpp +++ b/src/gui/bedit/bouqueteditor_bouquets.cpp @@ -169,11 +169,6 @@ void CBEBouquetWidget::paintFoot() footer.paintButtons(x, y + header_height + body_height, width, footer_height, numbuttons, CBEBouquetWidgetButtons); } -void CBEBouquetWidget::hide() -{ - frameBuffer->paintBackgroundBoxRel(x, y, width + OFFSET_SHADOW, height + OFFSET_SHADOW); -} - void CBEBouquetWidget::updateSelection(unsigned int newpos) { if (newpos == selected || newpos == (unsigned int)-1) diff --git a/src/gui/bedit/bouqueteditor_bouquets.h b/src/gui/bedit/bouqueteditor_bouquets.h index 439ae1d7b..0e1e6325a 100644 --- a/src/gui/bedit/bouqueteditor_bouquets.h +++ b/src/gui/bedit/bouqueteditor_bouquets.h @@ -68,7 +68,7 @@ class CBEBouquetWidget : public CBEGlobals, public CMenuTarget, public CListHelp void paintItem(int pos); void paintItems(); void paintFoot(); - void hide(); + void updateSelection(unsigned int newpos); void deleteBouquet(); @@ -93,6 +93,7 @@ class CBEBouquetWidget : public CBEGlobals, public CMenuTarget, public CListHelp //CZapitClient::BouquetList Bouquets; BouquetList * Bouquets; int exec(CMenuTarget* parent, const std::string & actionKey); + void hide(){CBEGlobals::hide();} }; #endif diff --git a/src/gui/bedit/bouqueteditor_channels.cpp b/src/gui/bedit/bouqueteditor_channels.cpp index 3bbb3c706..5417194f3 100644 --- a/src/gui/bedit/bouqueteditor_channels.cpp +++ b/src/gui/bedit/bouqueteditor_channels.cpp @@ -175,16 +175,6 @@ void CBEChannelWidget::paintFoot() footer.paintButtons(x, y + header_height + body_height, width, footer_height, numbuttons, CBEChannelWidgetButtons); } -void CBEChannelWidget::hide() -{ - frameBuffer->paintBackgroundBoxRel(x, y, width + OFFSET_SHADOW, height + OFFSET_SHADOW); - - if (dline) - dline->kill(); - if (ibox) - ibox->kill(); -} - std::string CBEChannelWidget::getInfoText(int index) { std::string res = ""; @@ -434,7 +424,7 @@ int CBEChannelWidget::exec(CMenuTarget* parent, const std::string & /*actionKey* CNeutrinoApp::getInstance()->handleMsg(msg, data); } } - hide(); + CBEGlobals::hide(); return res; } diff --git a/src/gui/bedit/bouqueteditor_channels.h b/src/gui/bedit/bouqueteditor_channels.h index 73f5512aa..d6f64c055 100644 --- a/src/gui/bedit/bouqueteditor_channels.h +++ b/src/gui/bedit/bouqueteditor_channels.h @@ -62,7 +62,7 @@ class CBEChannelWidget : public CBEGlobals, public CMenuTarget, public CListHelp void paintItems(); void paintFoot(); - void hide(); + void updateSelection(unsigned int newpos); void deleteChannel(); @@ -85,6 +85,7 @@ class CBEChannelWidget : public CBEGlobals, public CMenuTarget, public CListHelp //CZapitClient::BouquetChannelList Channels; ZapitChannelList * Channels; int exec(CMenuTarget* parent, const std::string & actionKey); + void hide(){CBEGlobals::hide();} bool hasChanged(); unsigned int getBouquet() { return bouquet; }; }; diff --git a/src/gui/bedit/bouqueteditor_chanselect.cpp b/src/gui/bedit/bouqueteditor_chanselect.cpp index 008997664..c4be1fb8a 100644 --- a/src/gui/bedit/bouqueteditor_chanselect.cpp +++ b/src/gui/bedit/bouqueteditor_chanselect.cpp @@ -180,16 +180,6 @@ void CBEChannelSelectWidget::paintFoot() footer.paintButtons(x, y + header_height + body_height, width, footer_height, numbuttons, CBEChannelSelectButtons); } -void CBEChannelSelectWidget::hide() -{ - frameBuffer->paintBackgroundBoxRel(x, y, width + OFFSET_SHADOW, height + OFFSET_SHADOW); - - if (dline) - dline->kill(); - if (ibox) - ibox->kill(); -} - std::string CBEChannelSelectWidget::getInfoText(int index) { std::string res = ""; diff --git a/src/gui/bedit/bouqueteditor_chanselect.h b/src/gui/bedit/bouqueteditor_chanselect.h index c54436fae..5766837b0 100644 --- a/src/gui/bedit/bouqueteditor_chanselect.h +++ b/src/gui/bedit/bouqueteditor_chanselect.h @@ -62,7 +62,7 @@ class CBEChannelSelectWidget : public CBEGlobals, public CMenuTarget, public CLi void paintItems(); void paintFoot(); - void hide(); + void updateSelection(unsigned int newpos); void sortChannels(); @@ -77,6 +77,7 @@ class CBEChannelSelectWidget : public CBEGlobals, public CMenuTarget, public CLi ZapitChannelList Channels; ZapitChannelList * bouquetChannels; int exec(CMenuTarget* parent, const std::string & actionKey); + void hide(){CBEGlobals::hide();} bool hasChanged(); }; diff --git a/src/gui/bedit/bouqueteditor_globals.cpp b/src/gui/bedit/bouqueteditor_globals.cpp index 4d624724c..df21cc1a0 100644 --- a/src/gui/bedit/bouqueteditor_globals.cpp +++ b/src/gui/bedit/bouqueteditor_globals.cpp @@ -109,4 +109,17 @@ void CBEGlobals::paintDetails(int pos, int current) } } +void CBEGlobals::hide() +{ + frameBuffer->paintBackgroundBoxRel(x, y, width + OFFSET_SHADOW, height + OFFSET_SHADOW); + killDetails(); +} + +void CBEGlobals::killDetails() +{ + if (dline) + dline->kill(); + if (ibox) + ibox->kill(); +} diff --git a/src/gui/bedit/bouqueteditor_globals.h b/src/gui/bedit/bouqueteditor_globals.h index af04c4e16..49e7724a4 100644 --- a/src/gui/bedit/bouqueteditor_globals.h +++ b/src/gui/bedit/bouqueteditor_globals.h @@ -34,6 +34,7 @@ class CBEGlobals virtual std::string getInfoText(int index) = 0; void paintDetails(int pos, int current); + void killDetails(); public: CBEGlobals(); @@ -64,6 +65,8 @@ class CBEGlobals int status_icon_width; int timeout; + + void hide(); }; #endif