fixed master panel window button localization
fix for issue #878, see http://bugs.campware.org/view.php?id=878
This commit is contained in:
parent
6cb75058f0
commit
7fb9e8e3e6
1 changed files with 32 additions and 11 deletions
|
@ -22,7 +22,7 @@
|
||||||
|
|
||||||
|
|
||||||
Author : $Author: maroy $
|
Author : $Author: maroy $
|
||||||
Version : $Revision: 1.22 $
|
Version : $Revision: 1.23 $
|
||||||
Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/products/gLiveSupport/src/MasterPanelWindow.cxx,v $
|
Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/products/gLiveSupport/src/MasterPanelWindow.cxx,v $
|
||||||
|
|
||||||
------------------------------------------------------------------------------*/
|
------------------------------------------------------------------------------*/
|
||||||
|
@ -156,6 +156,11 @@ MasterPanelWindow :: MasterPanelWindow (Ptr<GLiveSupport>::Ref gLiveSupport,
|
||||||
set_decorated(false);
|
set_decorated(false);
|
||||||
|
|
||||||
// set the localized resources
|
// set the localized resources
|
||||||
|
uploadFileButton = 0;
|
||||||
|
scratchpadButton = 0;
|
||||||
|
simplePlaylistMgmtButton = 0;
|
||||||
|
schedulerButton = 0;
|
||||||
|
searchButton = 0;
|
||||||
changeLanguage(bundle);
|
changeLanguage(bundle);
|
||||||
|
|
||||||
// show what's there to see
|
// show what's there to see
|
||||||
|
@ -185,21 +190,37 @@ MasterPanelWindow :: changeLanguage(Ptr<ResourceBundle>::Ref bundle)
|
||||||
{
|
{
|
||||||
setBundle(bundle);
|
setBundle(bundle);
|
||||||
|
|
||||||
|
if (uploadFileButton) {
|
||||||
|
buttonBar->remove(*uploadFileButton);
|
||||||
|
}
|
||||||
|
if (scratchpadButton) {
|
||||||
|
buttonBar->remove(*scratchpadButton);
|
||||||
|
}
|
||||||
|
if (simplePlaylistMgmtButton) {
|
||||||
|
buttonBar->remove(*simplePlaylistMgmtButton);
|
||||||
|
}
|
||||||
|
if (schedulerButton) {
|
||||||
|
buttonBar->remove(*schedulerButton);
|
||||||
|
}
|
||||||
|
if (searchButton) {
|
||||||
|
buttonBar->remove(*searchButton);
|
||||||
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
set_title(*getResourceUstring("windowTitle"));
|
set_title(*getResourceUstring("windowTitle"));
|
||||||
|
|
||||||
Ptr<WidgetFactory>::Ref wf = WidgetFactory::getInstance();
|
Ptr<WidgetFactory>::Ref wf = WidgetFactory::getInstance();
|
||||||
|
|
||||||
uploadFileButton = wf->createButton(
|
uploadFileButton = Gtk::manage(wf->createButton(
|
||||||
*getResourceUstring("uploadFileButtonLabel"));
|
*getResourceUstring("uploadFileButtonLabel")));
|
||||||
scratchpadButton = wf->createButton(
|
scratchpadButton = Gtk::manage(wf->createButton(
|
||||||
*getResourceUstring("scratchpadButtonLabel"));
|
*getResourceUstring("scratchpadButtonLabel")));
|
||||||
simplePlaylistMgmtButton = wf->createButton(
|
simplePlaylistMgmtButton = Gtk::manage(wf->createButton(
|
||||||
*getResourceUstring("simplePlaylistMgmtButtonLabel"));
|
*getResourceUstring("simplePlaylistMgmtButtonLabel")));
|
||||||
schedulerButton = wf->createButton(
|
schedulerButton = Gtk::manage(wf->createButton(
|
||||||
*getResourceUstring("schedulerButtonLabel"));
|
*getResourceUstring("schedulerButtonLabel")));
|
||||||
searchButton = wf->createButton(
|
searchButton = Gtk::manage(wf->createButton(
|
||||||
*getResourceUstring("searchButtonLabel"));
|
*getResourceUstring("searchButtonLabel")));
|
||||||
} catch (std::invalid_argument &e) {
|
} catch (std::invalid_argument &e) {
|
||||||
std::cerr << e.what() << std::endl;
|
std::cerr << e.what() << std::endl;
|
||||||
std::exit(1);
|
std::exit(1);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue