WebTools palette hides after switching mode from Internet to any other.

preferencesAboutTextFull
Aleksei Kanash 13 years ago
parent 19a3a78ed2
commit 9ac508f979
  1. 9
      src/board/UBBoardPaletteManager.cpp
  2. 4
      src/board/UBBoardPaletteManager.h
  3. 2
      src/web/UBWebController.cpp

@ -29,6 +29,7 @@
#include "gui/UBKeyboardPalette.h" #include "gui/UBKeyboardPalette.h"
#include "gui/UBToolWidget.h" #include "gui/UBToolWidget.h"
#include "gui/UBZoomPalette.h" #include "gui/UBZoomPalette.h"
#include "gui/UBWebToolsPalette.h"
#include "gui/UBActionPalette.h" #include "gui/UBActionPalette.h"
#include "gui/UBFavoriteToolPalette.h" #include "gui/UBFavoriteToolPalette.h"
#include "gui/UBDockTeacherGuideWidget.h" #include "gui/UBDockTeacherGuideWidget.h"
@ -73,6 +74,7 @@ UBBoardPaletteManager::UBBoardPaletteManager(QWidget* container, UBBoardControll
, mRightPalette(NULL) , mRightPalette(NULL)
, mBackgroundsPalette(0) , mBackgroundsPalette(0)
, mToolsPalette(0) , mToolsPalette(0)
, mWebToolsCurrentPalette(0)
, mAddItemPalette(0) , mAddItemPalette(0)
, mErasePalette(NULL) , mErasePalette(NULL)
, mPagePalette(NULL) , mPagePalette(NULL)
@ -683,6 +685,8 @@ void UBBoardPaletteManager::changeMode(eUBDockPaletteWidgetMode newMode, bool is
if( !isInit ) if( !isInit )
containerResized(); containerResized();
if (mWebToolsCurrentPalette)
mWebToolsCurrentPalette->hide();
} }
break; break;
@ -723,6 +727,9 @@ void UBBoardPaletteManager::changeMode(eUBDockPaletteWidgetMode newMode, bool is
if( !isInit ) if( !isInit )
UBApplication::applicationController->uninotesController()->TransparentWidgetResized(); UBApplication::applicationController->uninotesController()->TransparentWidgetResized();
if (mWebToolsCurrentPalette)
mWebToolsCurrentPalette->hide();
} }
break; break;
@ -764,6 +771,8 @@ void UBBoardPaletteManager::changeMode(eUBDockPaletteWidgetMode newMode, bool is
else else
mKeyboardPalette->setParent(UBApplication::documentController->controlView()); mKeyboardPalette->setParent(UBApplication::documentController->controlView());
} }
if (mWebToolsCurrentPalette)
mWebToolsCurrentPalette->hide();
} }
break; break;

@ -30,6 +30,7 @@
#include "gui/UBFeaturesWidget.h" #include "gui/UBFeaturesWidget.h"
class UBWebToolsPalette;
class UBStylusPalette; class UBStylusPalette;
class UBClockPalette; class UBClockPalette;
class UBPageNumberPalette; class UBPageNumberPalette;
@ -66,6 +67,9 @@ class UBBoardPaletteManager : public QObject
UBKeyboardPalette *mKeyboardPalette; UBKeyboardPalette *mKeyboardPalette;
void setCurrentWebToolsPalette(UBWebToolsPalette *palette) {mWebToolsCurrentPalette = palette;}
UBWebToolsPalette* mWebToolsCurrentPalette;
void processPalettersWidget(UBDockPalette *paletter, eUBDockPaletteWidgetMode mode); void processPalettersWidget(UBDockPalette *paletter, eUBDockPaletteWidgetMode mode);
void changeMode(eUBDockPaletteWidgetMode newMode, bool isInit = false); void changeMode(eUBDockPaletteWidgetMode newMode, bool isInit = false);
void startDownloads(); void startDownloads();

@ -424,7 +424,7 @@ void UBWebController::setupPalettes()
if(!(*mToolsCurrentPalette)) if(!(*mToolsCurrentPalette))
{ {
(*mToolsCurrentPalette) = new UBWebToolsPalette(UBApplication::mainWindow, false); (*mToolsCurrentPalette) = new UBWebToolsPalette(UBApplication::mainWindow, false);
UBApplication::boardController->paletteManager()->setCurrentWebToolsPalette(*mToolsCurrentPalette);
#ifndef Q_WS_WIN #ifndef Q_WS_WIN
if (UBPlatformUtils::hasVirtualKeyboard() && UBApplication::boardController->paletteManager()->mKeyboardPalette) if (UBPlatformUtils::hasVirtualKeyboard() && UBApplication::boardController->paletteManager()->mKeyboardPalette)
connect(UBApplication::boardController->paletteManager()->mKeyboardPalette, SIGNAL(closed()), connect(UBApplication::boardController->paletteManager()->mKeyboardPalette, SIGNAL(closed()),

Loading…
Cancel
Save