forked from qt-creator/qt-creator
Merge remote-tracking branch 'origin/2.8' into 3.0
This commit is contained in:
@@ -44,6 +44,14 @@ GroupBox {
|
|||||||
property variant underlineStyle: backendValues.font_underline
|
property variant underlineStyle: backendValues.font_underline
|
||||||
property variant strikeoutStyle: backendValues.font_strikeout
|
property variant strikeoutStyle: backendValues.font_strikeout
|
||||||
|
|
||||||
|
onPointSizeChanged: {
|
||||||
|
sizeWidget.setPointPixelSize();
|
||||||
|
}
|
||||||
|
|
||||||
|
onPixelSizeChanged: {
|
||||||
|
sizeWidget.setPointPixelSize();
|
||||||
|
}
|
||||||
|
|
||||||
layout: VerticalLayout {
|
layout: VerticalLayout {
|
||||||
|
|
||||||
QWidget {
|
QWidget {
|
||||||
@@ -61,17 +69,22 @@ GroupBox {
|
|||||||
QWidget {
|
QWidget {
|
||||||
id: sizeWidget
|
id: sizeWidget
|
||||||
property bool selectionFlag: selectionChanged
|
property bool selectionFlag: selectionChanged
|
||||||
|
|
||||||
property bool pixelSize: sizeType.currentText == "pixels"
|
property bool pixelSize: sizeType.currentText == "pixels"
|
||||||
property bool isSetup;
|
property bool isSetup;
|
||||||
|
|
||||||
onSelectionFlagChanged: {
|
function setPointPixelSize() {
|
||||||
isSetup = true;
|
isSetup = true;
|
||||||
sizeType.currentText = "points";
|
sizeType.currentText = "points";
|
||||||
if (pixelSize.isInModel)
|
if (fontGroupBox.pixelSize.isInModel)
|
||||||
sizeType.currentText = "pixels";
|
sizeType.currentText = "pixels";
|
||||||
isSetup = false;
|
isSetup = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
onSelectionFlagChanged: {
|
||||||
|
setPointPixelSize();
|
||||||
|
}
|
||||||
|
|
||||||
layout: HorizontalLayout {
|
layout: HorizontalLayout {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Size")
|
text: qsTr("Size")
|
||||||
|
|||||||
@@ -212,7 +212,7 @@ void StashDialog::showCurrent()
|
|||||||
{
|
{
|
||||||
const int index = currentRow();
|
const int index = currentRow();
|
||||||
QTC_ASSERT(index >= 0, return);
|
QTC_ASSERT(index >= 0, return);
|
||||||
gitClient()->show(m_repository, m_model->at(index).name);
|
gitClient()->show(m_repository, QString(m_model->at(index).name));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Suggest Branch name to restore 'stash@{0}' -> 'stash0-date'
|
// Suggest Branch name to restore 'stash@{0}' -> 'stash0-date'
|
||||||
|
|||||||
@@ -40,6 +40,7 @@
|
|||||||
#include <qmljs/qmljsscopechain.h>
|
#include <qmljs/qmljsscopechain.h>
|
||||||
#include <qmljs/parser/qmljsast_p.h>
|
#include <qmljs/parser/qmljsast_p.h>
|
||||||
#include <qmljs/qmljsmodelmanagerinterface.h>
|
#include <qmljs/qmljsmodelmanagerinterface.h>
|
||||||
|
#include <languageutils/fakemetaobject.h>
|
||||||
|
|
||||||
namespace QmlDesigner {
|
namespace QmlDesigner {
|
||||||
|
|
||||||
@@ -775,8 +776,20 @@ QString NodeMetaInfoPrivate::propertyEnumScope(const PropertyName &propertyName)
|
|||||||
return QString();
|
return QString();
|
||||||
const CppComponentValue *definedIn = 0;
|
const CppComponentValue *definedIn = 0;
|
||||||
qmlObjectValue->getEnum(propertyType(propertyName), &definedIn);
|
qmlObjectValue->getEnum(propertyType(propertyName), &definedIn);
|
||||||
if (definedIn)
|
if (definedIn) {
|
||||||
|
QString nonCppPackage;
|
||||||
|
foreach (const LanguageUtils::FakeMetaObject::Export &qmlExport, definedIn->metaObject()->exports()) {
|
||||||
|
if (qmlExport.package != QLatin1String("<cpp>"))
|
||||||
|
nonCppPackage = qmlExport.package;
|
||||||
|
}
|
||||||
|
|
||||||
|
const LanguageUtils::FakeMetaObject::Export qmlExport =
|
||||||
|
definedIn->metaObject()->exportInPackage(nonCppPackage);
|
||||||
|
if (qmlExport.isValid())
|
||||||
|
return qmlExport.type;
|
||||||
|
|
||||||
return definedIn->className();
|
return definedIn->className();
|
||||||
|
}
|
||||||
|
|
||||||
return QString();
|
return QString();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user