Merge branch 'master' of https://github.com/worklist/hifi into modelserver

This commit is contained in:
ZappoMan 2014-05-05 12:39:36 -07:00
commit ccadf3be57
4 changed files with 9 additions and 4 deletions

View file

@ -331,8 +331,9 @@ function ScaleSelector() {
}); });
this.setScale = function(scale) { this.setScale = function(scale) {
this.scale = scale; this.scale = scale;
this.power = Math.floor(Math.log(scale)); this.power = Math.floor(Math.log(scale) / Math.log(2));
rescaleImport(); rescaleImport();
this.update();
} }
this.show = function(doShow) { this.show = function(doShow) {
@ -835,7 +836,6 @@ function showPreviewLines() {
if (copyScale) { if (copyScale) {
scaleSelector.setScale(intersection.voxel.s); scaleSelector.setScale(intersection.voxel.s);
scaleSelector.update();
} }
moveTools(); moveTools();
} else { } else {

View file

@ -10,6 +10,7 @@
// //
#include "MainWindow.h" #include "MainWindow.h"
#include "Menu.h"
#include <QEvent> #include <QEvent>
#include <QMoveEvent> #include <QMoveEvent>
@ -56,6 +57,10 @@ void MainWindow::changeEvent(QEvent* event) {
} else { } else {
emit windowShown(true); emit windowShown(true);
} }
if (isFullScreen() != Menu::getInstance()->isOptionChecked(MenuOption::Fullscreen)) {
Menu::getInstance()->setIsOptionChecked(MenuOption::Fullscreen, isFullScreen());
}
} else if (event->type() == QEvent::ActivationChange) { } else if (event->type() == QEvent::ActivationChange) {
if (isActiveWindow()) { if (isActiveWindow()) {
emit windowShown(true); emit windowShown(true);

View file

@ -19,7 +19,7 @@ ScriptLineNumberArea::ScriptLineNumberArea(ScriptEditBox* scriptEditBox) :
_scriptEditBox = scriptEditBox; _scriptEditBox = scriptEditBox;
} }
QSize ScriptLineNumberArea::sizeHint() { QSize ScriptLineNumberArea::sizeHint() const {
return QSize(_scriptEditBox->lineNumberAreaWidth(), 0); return QSize(_scriptEditBox->lineNumberAreaWidth(), 0);
} }

View file

@ -19,7 +19,7 @@ class ScriptLineNumberArea : public QWidget {
public: public:
ScriptLineNumberArea(ScriptEditBox* scriptEditBox); ScriptLineNumberArea(ScriptEditBox* scriptEditBox);
QSize sizeHint(); QSize sizeHint() const;
protected: protected:
void paintEvent(QPaintEvent* event); void paintEvent(QPaintEvent* event);