forked from qt-creator/qt-creator
Fixed compiler/lupdate/uic warnings.
Add missing Q_OBJECTS where tr() was used.
This commit is contained in:
@@ -126,16 +126,6 @@ void StyleHelper::setBaseColor(const QColor &color)
|
||||
}
|
||||
}
|
||||
|
||||
static QColor mergedColors(const QColor &colorA, const QColor &colorB, int factor = 50)
|
||||
{
|
||||
const int maxFactor = 100;
|
||||
QColor tmp = colorA;
|
||||
tmp.setRed((tmp.red() * factor) / maxFactor + (colorB.red() * (maxFactor - factor)) / maxFactor);
|
||||
tmp.setGreen((tmp.green() * factor) / maxFactor + (colorB.green() * (maxFactor - factor)) / maxFactor);
|
||||
tmp.setBlue((tmp.blue() * factor) / maxFactor + (colorB.blue() * (maxFactor - factor)) / maxFactor);
|
||||
return tmp;
|
||||
}
|
||||
|
||||
void StyleHelper::verticalGradient(QPainter *painter, const QRect &spanRect, const QRect &clipRect)
|
||||
{
|
||||
QString key;
|
||||
|
@@ -37,6 +37,7 @@ namespace Internal {
|
||||
|
||||
class CheckoutWizard : public VCSBase::BaseCheckoutWizard
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit CheckoutWizard(QObject *parent = 0);
|
||||
|
||||
|
@@ -98,10 +98,6 @@
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
<zorder></zorder>
|
||||
<zorder>checkBoxDebugDebuggingHelpers</zorder>
|
||||
<zorder>checkBoxUseDebuggingHelpers</zorder>
|
||||
<zorder></zorder>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
|
@@ -356,6 +356,7 @@ void GenericProject::setToolChainId(const QString &toolChainId)
|
||||
|
||||
QString GenericProject::buildParser(const QString &buildConfiguration) const
|
||||
{
|
||||
Q_UNUSED(buildConfiguration)
|
||||
if (m_toolChain) {
|
||||
switch (m_toolChain->type()) {
|
||||
case ProjectExplorer::ToolChain::GCC:
|
||||
@@ -448,6 +449,7 @@ GenericProjectNode *GenericProject::rootProjectNode() const
|
||||
|
||||
QStringList GenericProject::files(FilesMode fileMode) const
|
||||
{
|
||||
Q_UNUSED(fileMode)
|
||||
return m_files; // ### TODO: handle generated files here.
|
||||
}
|
||||
|
||||
|
@@ -37,6 +37,7 @@ namespace Internal {
|
||||
|
||||
class CloneWizard : public VCSBase::BaseCheckoutWizard
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit CloneWizard(QObject *parent = 0);
|
||||
|
||||
|
@@ -39,6 +39,7 @@ namespace Internal {
|
||||
// Gitorious-hosted projects.
|
||||
class GitoriousCloneWizard : public VCSBase::BaseCheckoutWizard
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit GitoriousCloneWizard(QObject *parent = 0);
|
||||
|
||||
|
@@ -39,6 +39,7 @@ class GettingStartedWelcomePageWidget;
|
||||
|
||||
class GettingStartedWelcomePage : public ExtensionSystem::IWelcomePage
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
GettingStartedWelcomePage();
|
||||
|
||||
|
@@ -27,6 +27,8 @@ bool QtScriptCodeCompletion::supportsEditor(TextEditor::ITextEditable *editor)
|
||||
#if 0 // ### disable JS Completion. It's pretty buggy and it can crash Creator.
|
||||
if (qobject_cast<ScriptEditor *>(editor->widget()))
|
||||
return true;
|
||||
#else
|
||||
Q_UNUSED(editor)
|
||||
#endif
|
||||
|
||||
return false;
|
||||
|
@@ -37,6 +37,7 @@ namespace Internal {
|
||||
|
||||
class CheckoutWizard : public VCSBase::BaseCheckoutWizard
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit CheckoutWizard(QObject *parent = 0);
|
||||
|
||||
|
@@ -39,8 +39,8 @@ namespace Internal {
|
||||
|
||||
CommunityWelcomePageWidget::CommunityWelcomePageWidget(QWidget *parent) :
|
||||
QWidget(parent),
|
||||
ui(new Ui::CommunityWelcomePageWidget),
|
||||
m_rssFetcher(new RSSFetcher(7))
|
||||
m_rssFetcher(new RSSFetcher(7)),
|
||||
ui(new Ui::CommunityWelcomePageWidget)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
ui->labsTitleLabel->setStyledText(tr("News From the Qt Labs"));
|
||||
|
@@ -454,7 +454,7 @@ void QScriptHighlighter::highlightKeyword(int currentPos, const QString &buffer)
|
||||
if (buffer.isEmpty())
|
||||
return;
|
||||
|
||||
if (m_duiEnabled && buffer.at(0).isUpper() || (! m_duiEnabled && buffer.at(0) == QLatin1Char('Q'))) {
|
||||
if ((m_duiEnabled && buffer.at(0).isUpper()) || (! m_duiEnabled && buffer.at(0) == QLatin1Char('Q'))) {
|
||||
setFormat(currentPos - buffer.length(), buffer.length(), m_formats[TypeFormat]);
|
||||
} else {
|
||||
if (qscriptKeywords.contains(buffer))
|
||||
|
Reference in New Issue
Block a user