Merge "Merge remote-tracking branch 'origin/5.8' into dev" into refs/staging/dev
This commit is contained in:
commit
60e3bfe958
2
.gitignore
vendored
2
.gitignore
vendored
@ -202,7 +202,7 @@ src/3rdparty/webkit/includes2.txt
|
||||
# generated files in configure.exe bootstrapping
|
||||
tools/configure/configure.intermediate.manifest
|
||||
tools/configure/configure_pch.pch
|
||||
/configure.exe
|
||||
/configureapp.exe
|
||||
|
||||
# Symlinks generated by configure
|
||||
tools/qvfb/qvfbhdr.h
|
||||
|
@ -1,3 +1,2 @@
|
||||
SOURCES = fontconfig.cpp
|
||||
CONFIG -= qt
|
||||
include(../../unix/freetype/freetype.pri)
|
||||
|
@ -1,15 +0,0 @@
|
||||
!cross_compile {
|
||||
TRY_INCLUDEPATHS = /include /usr/include $$QMAKE_INCDIR $$QMAKE_INCDIR_X11 $$INCLUDEPATH
|
||||
# LSB doesn't allow using headers from /include or /usr/include
|
||||
linux-lsb-g++:TRY_INCLUDEPATHS = $$QMAKE_INCDIR $$QMAKE_INCDIR_X11 $$INCLUDEPATH
|
||||
haiku:TRY_INCLUDEPATHS += /system/develop/headers
|
||||
for(p, TRY_INCLUDEPATHS) {
|
||||
p = $$join(p, "", "", "/freetype2")
|
||||
exists($$p):INCLUDEPATH *= $$p
|
||||
}
|
||||
} else {
|
||||
# If we are cross-compiling, then there is still a remote possibility that
|
||||
# configure detected font-config & freetype, stored in these variables.
|
||||
QMAKE_CFLAGS += $$QMAKE_CFLAGS_FONTCONFIG
|
||||
QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_FONTCONFIG
|
||||
}
|
@ -1,3 +1,2 @@
|
||||
SOURCES = freetype.cpp
|
||||
CONFIG -= qt
|
||||
include(freetype.pri)
|
||||
|
46
config.tests/unix/libinput_axis_api/libinput_axis_api.cpp
Normal file
46
config.tests/unix/libinput_axis_api/libinput_axis_api.cpp
Normal file
@ -0,0 +1,46 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2016 The Qt Company Ltd.
|
||||
** Contact: https://www.qt.io/licensing/
|
||||
**
|
||||
** This file is part of the config.tests of the Qt Toolkit.
|
||||
**
|
||||
** $QT_BEGIN_LICENSE:LGPL$
|
||||
** Commercial License Usage
|
||||
** Licensees holding valid commercial Qt licenses may use this file in
|
||||
** accordance with the commercial license agreement provided with the
|
||||
** Software or, alternatively, in accordance with the terms contained in
|
||||
** a written agreement between you and The Qt Company. For licensing terms
|
||||
** and conditions see https://www.qt.io/terms-conditions. For further
|
||||
** information use the contact form at https://www.qt.io/contact-us.
|
||||
**
|
||||
** GNU Lesser General Public License Usage
|
||||
** Alternatively, this file may be used under the terms of the GNU Lesser
|
||||
** General Public License version 3 as published by the Free Software
|
||||
** Foundation and appearing in the file LICENSE.LGPL3 included in the
|
||||
** packaging of this file. Please review the following information to
|
||||
** ensure the GNU Lesser General Public License version 3 requirements
|
||||
** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
|
||||
**
|
||||
** GNU General Public License Usage
|
||||
** Alternatively, this file may be used under the terms of the GNU
|
||||
** General Public License version 2.0 or (at your option) the GNU General
|
||||
** Public license version 3 or any later version approved by the KDE Free
|
||||
** Qt Foundation. The licenses are as published by the Free Software
|
||||
** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
|
||||
** included in the packaging of this file. Please review the following
|
||||
** information to ensure the GNU General Public License requirements will
|
||||
** be met: https://www.gnu.org/licenses/gpl-2.0.html and
|
||||
** https://www.gnu.org/licenses/gpl-3.0.html.
|
||||
**
|
||||
** $QT_END_LICENSE$
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#include <libinput.h>
|
||||
|
||||
int main()
|
||||
{
|
||||
libinput_event_pointer_has_axis(nullptr, LIBINPUT_POINTER_AXIS_SCROLL_VERTICAL);
|
||||
return 0;
|
||||
}
|
@ -0,0 +1,2 @@
|
||||
SOURCES = libinput_axis_api.cpp
|
||||
CONFIG -= qt
|
@ -46,7 +46,7 @@ Conventions for the remaining options: When an option's description is
|
||||
followed by a list of values in brackets, the interpretation is as follows:
|
||||
'yes' represents the bare option; all other values are possible prefixes to
|
||||
the option, e.g., -no-gui. Alternatively, the value can be assigned, e.g.,
|
||||
-gui=yes. Values are listed in the order they are tried if not specified;
|
||||
--gui=yes. Values are listed in the order they are tried if not specified;
|
||||
'auto' is a shorthand for 'yes/no'. Solitary 'yes' and 'no' represent binary
|
||||
options without auto-detection.
|
||||
|
||||
|
@ -130,7 +130,7 @@ if errorlevel 1 (cd ..\.. & exit /b 1)
|
||||
cd ..\..
|
||||
|
||||
:conf
|
||||
configure.exe -srcdir %QTSRC% %ARGS%
|
||||
configureapp.exe -srcdir %QTSRC% %ARGS%
|
||||
goto exit
|
||||
|
||||
:help
|
||||
|
7
doc/doc.pro
Normal file
7
doc/doc.pro
Normal file
@ -0,0 +1,7 @@
|
||||
TEMPLATE = aux
|
||||
|
||||
global_docs.files = $$PWD/global
|
||||
global_docs.path = $$[QT_INSTALL_DOCS]
|
||||
INSTALLS += global_docs
|
||||
!prefix_build:!equals(OUT_PWD, $$PWD): \
|
||||
COPIES += global_docs
|
@ -110,12 +110,13 @@ void Client::readFortune()
|
||||
in.setVersion(QDataStream::Qt_4_0);
|
||||
|
||||
if (blockSize == 0) {
|
||||
if (socket->bytesAvailable() < (int)sizeof(quint16))
|
||||
// Relies on the fact that QDataStream format streams a quint32 into sizeof(quint32) bytes
|
||||
if (socket->bytesAvailable() < (int)sizeof(quint32))
|
||||
return;
|
||||
in >> blockSize;
|
||||
}
|
||||
|
||||
if (in.atEnd())
|
||||
if (socket->bytesAvailable() < blockSize || in.atEnd())
|
||||
return;
|
||||
|
||||
QString nextFortune;
|
||||
|
@ -86,7 +86,7 @@ private:
|
||||
|
||||
QLocalSocket *socket;
|
||||
QString currentFortune;
|
||||
quint16 blockSize;
|
||||
quint32 blockSize;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -106,10 +106,10 @@ void Server::sendFortune()
|
||||
QByteArray block;
|
||||
QDataStream out(&block, QIODevice::WriteOnly);
|
||||
out.setVersion(QDataStream::Qt_4_0);
|
||||
out << (quint16)0;
|
||||
out << (quint32)0;
|
||||
out << fortunes.at(qrand() % fortunes.size());
|
||||
out.device()->seek(0);
|
||||
out << (quint16)(block.size() - sizeof(quint16));
|
||||
out << (quint32)(block.size() - sizeof(quint32));
|
||||
|
||||
QLocalSocket *clientConnection = server->nextPendingConnection();
|
||||
connect(clientConnection, SIGNAL(disconnected()),
|
||||
|
@ -15,7 +15,7 @@ SUBDIRS = \
|
||||
widgets \
|
||||
xml
|
||||
|
||||
qtConfig(opengl): SUBDIRS += opengl
|
||||
qtHaveModule(gui):qtConfig(opengl): SUBDIRS += opengl
|
||||
|
||||
aggregate.files = aggregate/examples.pro
|
||||
aggregate.path = $$[QT_INSTALL_EXAMPLES]
|
||||
|
@ -3,7 +3,7 @@ MAKEFILE_GENERATOR = UNIX
|
||||
QMAKE_PLATFORM = android
|
||||
QMAKE_COMPILER = gcc clang llvm
|
||||
|
||||
CONFIG += android_install unversioned_soname unversioned_libname android_deployment_settings
|
||||
CONFIG += android_install unversioned_soname unversioned_libname plugin_with_soname android_deployment_settings
|
||||
|
||||
include(../common/linux.conf)
|
||||
include(../common/clang.conf)
|
||||
|
@ -34,8 +34,6 @@
|
||||
#ifndef QPLATFORMDEFS_H
|
||||
#define QPLATFORMDEFS_H
|
||||
|
||||
#define QT_QPA_DEFAULT_PLATFORM_NAME "android"
|
||||
|
||||
// Get Qt defines/settings
|
||||
|
||||
#include "qglobal.h"
|
||||
|
@ -3,7 +3,7 @@ MAKEFILE_GENERATOR = UNIX
|
||||
QMAKE_PLATFORM = android
|
||||
QMAKE_COMPILER = gcc
|
||||
|
||||
CONFIG += android_install unversioned_soname unversioned_libname android_deployment_settings
|
||||
CONFIG += android_install unversioned_soname unversioned_libname plugin_with_soname android_deployment_settings
|
||||
|
||||
include(../common/linux.conf)
|
||||
include(../common/gcc-base-unix.conf)
|
||||
|
@ -40,8 +40,6 @@
|
||||
#ifndef QPLATFORMDEFS_H
|
||||
#define QPLATFORMDEFS_H
|
||||
|
||||
#define QT_QPA_DEFAULT_PLATFORM_NAME "android"
|
||||
|
||||
// Get Qt defines/settings
|
||||
|
||||
#include "qglobal.h"
|
||||
|
@ -36,7 +36,6 @@ QMAKE_LIBS_OPENGL_ES2 = -lGLESv2
|
||||
QMAKE_LIBS_OPENVG = -lOpenVG
|
||||
QMAKE_LIBS_THREAD = -lpthread
|
||||
|
||||
QMAKE_CFLAGS_WAYLAND =
|
||||
QMAKE_INCDIR_WAYLAND =
|
||||
QMAKE_LIBS_WAYLAND_CLIENT = -lwayland-client
|
||||
QMAKE_LIBS_WAYLAND_SERVER = -lwayland-server
|
||||
|
@ -33,6 +33,8 @@ QMAKE_LIBS_DYNLOAD =
|
||||
QMAKE_LIBS_OPENGL = -framework OpenGL -framework AGL
|
||||
QMAKE_LIBS_THREAD =
|
||||
|
||||
QMAKE_ACTOOL = actool
|
||||
|
||||
QMAKE_DSYMUTIL = dsymutil
|
||||
QMAKE_STRIP = strip
|
||||
QMAKE_STRIPFLAGS_LIB += -S -x
|
||||
|
@ -6,9 +6,6 @@ include(qcc-base.conf)
|
||||
|
||||
QMAKE_PLATFORM = qnx $$QMAKE_PLATFORM
|
||||
|
||||
#Choose qnx QPA Plugin as default
|
||||
QT_QPA_DEFAULT_PLATFORM = qnx
|
||||
|
||||
QMAKE_LFLAGS_SHLIB += -shared
|
||||
QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
|
||||
QMAKE_LFLAGS_SONAME += -Wl,-soname,
|
||||
|
@ -2,8 +2,6 @@
|
||||
# Common build settings for all iOS/tvOS/watchOS configurations
|
||||
#
|
||||
|
||||
QT_QPA_DEFAULT_PLATFORM = ios
|
||||
|
||||
QMAKE_XCODE_CODE_SIGN_IDENTITY = "iPhone Developer"
|
||||
|
||||
# iOS build tools
|
||||
|
@ -1,5 +1,5 @@
|
||||
<?xml version=\"1.0\" encoding=\"utf-8\"?>
|
||||
<Package xmlns=\"http://schemas.microsoft.com/appx/2010/manifest\" xmlns:m3=\"http://schemas.microsoft.com/appx/2014/manifest\" xmlns:mp=\"http://schemas.microsoft.com/appx/2014/phone/manifest\">
|
||||
<Package xmlns=\"http://schemas.microsoft.com/appx/2010/manifest\" xmlns:m2=\"http://schemas.microsoft.com/appx/2013/manifest\" xmlns:m3=\"http://schemas.microsoft.com/appx/2014/manifest\" xmlns:mp=\"http://schemas.microsoft.com/appx/2014/phone/manifest\">
|
||||
<Identity
|
||||
Name=\"$${WINRT_MANIFEST.identity}\"
|
||||
ProcessorArchitecture=\"$${WINRT_MANIFEST.architecture}\"
|
||||
|
@ -116,29 +116,6 @@ c++11|c++14|c++1z {
|
||||
unset(cxxstd)
|
||||
}
|
||||
|
||||
suffix =
|
||||
for(ever) {
|
||||
QMAKE_USE$${suffix} = $$unique(QMAKE_USE$${suffix})
|
||||
for(name, QMAKE_USE$${suffix}) {
|
||||
nu = $$upper($$name)
|
||||
CONFIG(debug, debug|release): \
|
||||
libs = $$eval(QMAKE_LIBS_$${nu}_DEBUG)
|
||||
else: \
|
||||
libs = $$eval(QMAKE_LIBS_$${nu}_RELEASE)
|
||||
libs += $$eval(QMAKE_LIBS_$$nu)
|
||||
cflags = $$eval(QMAKE_CFLAGS_$${nu})
|
||||
|
||||
isEmpty(libs):isEmpty(cflags): \
|
||||
error("Library '$$name' is not defined.")
|
||||
|
||||
LIBS$${suffix} += $$libs
|
||||
QMAKE_CFLAGS += $$cflags
|
||||
QMAKE_CXXFLAGS += $$cflags
|
||||
}
|
||||
!isEmpty(suffix): break()
|
||||
suffix = "_PRIVATE"
|
||||
}
|
||||
|
||||
!precompile_header: SOURCES += $$NO_PCH_SOURCES
|
||||
|
||||
QMAKE_INCDIR += $$QMAKE_INCDIR_POST
|
||||
|
109
mkspecs/features/mac/asset_catalogs.prf
Normal file
109
mkspecs/features/mac/asset_catalogs.prf
Normal file
@ -0,0 +1,109 @@
|
||||
# QMAKE_ASSET_CATALOGS
|
||||
# Paths to xcassets directories to be compiled
|
||||
#
|
||||
# QMAKE_ASSET_CATALOGS_BUILD_PATH
|
||||
# Location which asset catalogs will be compiled to.
|
||||
# If the current target is an app bundle, defaults to its Resources directory.
|
||||
# Otherwise, this value must be set manually.
|
||||
#
|
||||
# QMAKE_ASSET_CATALOGS_APP_ICON
|
||||
# Name of the icon resource in the asset catalogs that will be used as the app icon.
|
||||
# Defaults to AppIcon.
|
||||
#
|
||||
# QMAKE_ASSET_CATALOGS_INSTALL_PATH
|
||||
# Base path to install files to. Falls back to a path relative to the target install path,
|
||||
# based on QMAKE_ASSET_CATALOGS_BUILD_PATH.
|
||||
|
||||
!have_target|if(!build_pass:!isEmpty(BUILDS)): \
|
||||
return()
|
||||
|
||||
!isEmpty(QMAKE_ASSET_CATALOGS) {
|
||||
load(resolve_target)
|
||||
|
||||
isEmpty(QMAKE_ASSET_CATALOGS_BUILD_PATH) {
|
||||
!isEmpty(QMAKE_RESOLVED_BUNDLE):equals(TEMPLATE, app):app_bundle {
|
||||
macos: \
|
||||
QMAKE_ASSET_CATALOGS_BUILD_PATH = $$QMAKE_RESOLVED_BUNDLE/Contents/Resources
|
||||
else: \
|
||||
QMAKE_ASSET_CATALOGS_BUILD_PATH = $$QMAKE_RESOLVED_BUNDLE
|
||||
} else {
|
||||
error("QMAKE_ASSET_CATALOGS_BUILD_PATH must be set when using QMAKE_ASSET_CATALOGS.")
|
||||
}
|
||||
}
|
||||
|
||||
QMAKE_ASSET_CATALOGS_BUILD_PATH = $$clean_path($$QMAKE_ASSET_CATALOGS_BUILD_PATH)
|
||||
|
||||
macx-xcode {
|
||||
!isEmpty(QMAKE_ASSET_CATALOGS_APP_ICON) {
|
||||
asset_catalog_appicon.name = "ASSETCATALOG_COMPILER_APPICON_NAME"
|
||||
asset_catalog_appicon.value = $$QMAKE_ASSET_CATALOGS_APP_ICON
|
||||
QMAKE_MAC_XCODE_SETTINGS += asset_catalog_appicon
|
||||
}
|
||||
|
||||
asset_catalog_compiler.files = $$QMAKE_ASSET_CATALOGS
|
||||
macos: asset_catalog_compiler.path = Contents/Resources
|
||||
QMAKE_BUNDLE_DATA += asset_catalog_compiler
|
||||
} else {
|
||||
!isEmpty(QMAKE_ASSET_CATALOGS_APP_ICON) {
|
||||
asset_catalog_app_icon_arg = \
|
||||
--app-icon $$shell_quote($$QMAKE_ASSET_CATALOGS_APP_ICON)
|
||||
}
|
||||
|
||||
asset_catalog_compiler.target = $$OUT_PWD/asset_catalog_compiler.Info.plist
|
||||
asset_catalog_compiler.commands = $$shell_quote($$QMAKE_ACTOOL) \
|
||||
$$asset_catalog_app_icon_arg \
|
||||
--output-partial-info-plist $$shell_quote($$asset_catalog_compiler.target) \
|
||||
--platform $${version_identifier} \
|
||||
--minimum-deployment-target $${deployment_target} \
|
||||
--compile $$shell_quote($$QMAKE_ASSET_CATALOGS_BUILD_PATH)
|
||||
|
||||
for (catalog, QMAKE_ASSET_CATALOGS) {
|
||||
asset_catalog_compiler.commands += $${catalog}
|
||||
asset_catalog_compiler.depends += $$files($$catalog/*, true)
|
||||
}
|
||||
|
||||
actool_output_files = $$system(\
|
||||
mkdir -p $$system_quote($$QMAKE_ASSET_CATALOGS_BUILD_PATH) && \
|
||||
/usr/libexec/PlistBuddy -c \'Print :com.apple.actool.compilation-results:output-files\' \
|
||||
/dev/stdin <<< $($${asset_catalog_compiler.commands} 2>/dev/null) | grep \'^ .*$\', lines)
|
||||
|
||||
for (output_file, actool_output_files) {
|
||||
!equals(output_file, $$asset_catalog_compiler.target): \
|
||||
actool_output_files_rel += $$relative_path($$output_file, $$QMAKE_ASSET_CATALOGS_BUILD_PATH)
|
||||
}
|
||||
|
||||
QMAKE_EXTRA_TARGETS += asset_catalog_compiler
|
||||
PRE_TARGETDEPS += $$asset_catalog_compiler.target
|
||||
|
||||
isEmpty(QMAKE_ASSET_CATALOGS_INSTALL_PATH) {
|
||||
!isEmpty(target.path): \
|
||||
QMAKE_ASSET_CATALOGS_INSTALL_PATH = $${target.path}/
|
||||
QMAKE_ASSET_CATALOGS_INSTALL_PATH = $${QMAKE_ASSET_CATALOGS_INSTALL_PATH}$$relative_path(\
|
||||
$$QMAKE_ASSET_CATALOGS_BUILD_PATH, $$absolute_path($$DESTDIR, $$OUT_PWD))
|
||||
}
|
||||
|
||||
for (ac_install_file, actool_output_files_rel) {
|
||||
asset_catalogs_files.files += \
|
||||
$$QMAKE_ASSET_CATALOGS_BUILD_PATH/$$ac_install_file
|
||||
}
|
||||
contains(INSTALLS, target): asset_catalogs_files.depends += install_target
|
||||
asset_catalogs_files.path = $$QMAKE_ASSET_CATALOGS_INSTALL_PATH
|
||||
asset_catalogs_files.CONFIG += no_check_exist
|
||||
INSTALLS += asset_catalogs_files
|
||||
}
|
||||
} else: macx-xcode {
|
||||
# Backwards compatibility
|
||||
for (bundle_data, QMAKE_BUNDLE_DATA) {
|
||||
for (bundle_file, $${bundle_data}.files) {
|
||||
!contains(bundle_file, .*\.xcassets$): next()
|
||||
warning("*.xcassets in QMAKE_BUNDLE_DATA is deprecated. Use QMAKE_ASSET_CATALOGS instead.")
|
||||
!exists($$absolute_path($$bundle_file/AppIcon.appiconset, $$_PRO_FILE_PWD_)): next()
|
||||
|
||||
asset_catalog_appicon.name = "ASSETCATALOG_COMPILER_APPICON_NAME"
|
||||
asset_catalog_appicon.value = "AppIcon"
|
||||
QMAKE_MAC_XCODE_SETTINGS += asset_catalog_appicon
|
||||
break()
|
||||
}
|
||||
!isEmpty(asset_catalog_appicon.name): break()
|
||||
}
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
CONFIG = sdk rez $$CONFIG
|
||||
CONFIG = asset_catalogs sdk rez $$CONFIG
|
||||
load(default_pre)
|
||||
|
||||
isEmpty(QMAKE_XCODE_DEVELOPER_PATH) {
|
||||
@ -33,6 +33,8 @@ isEmpty(QMAKE_TARGET_BUNDLE_PREFIX) {
|
||||
cache(QMAKE_TARGET_BUNDLE_PREFIX)
|
||||
}
|
||||
|
||||
QMAKE_ASSET_CATALOGS_APP_ICON = AppIcon
|
||||
|
||||
# Make the default debug info format for static debug builds
|
||||
# DWARF instead of DWARF with dSYM. This cuts down build times
|
||||
# for application debug builds significantly, as Xcode doesn't
|
||||
|
@ -31,7 +31,7 @@ QMAKE_INCDIR_OPENGL = $$sysrootified
|
||||
QMAKESPEC_NAME = $$basename(QMAKESPEC)
|
||||
|
||||
# Resolve SDK version of various tools
|
||||
for(tool, $$list(QMAKE_CC QMAKE_CXX QMAKE_FIX_RPATH QMAKE_AR QMAKE_RANLIB QMAKE_LINK QMAKE_LINK_SHLIB)) {
|
||||
for(tool, $$list(QMAKE_CC QMAKE_CXX QMAKE_FIX_RPATH QMAKE_AR QMAKE_RANLIB QMAKE_LINK QMAKE_LINK_SHLIB QMAKE_ACTOOL)) {
|
||||
tool_variable = QMAKE_MAC_SDK.$${QMAKESPEC_NAME}.$${QMAKE_MAC_SDK}.$${tool}
|
||||
!isEmpty($$tool_variable) {
|
||||
$$tool = $$eval($$tool_variable)
|
||||
|
@ -32,7 +32,7 @@ if(gcc|intel_icl|msvc):!rim_qcc:!uikit:if(!macos|count(QMAKE_APPLE_DEVICE_ARCHS,
|
||||
gcc: moc_predefs.commands = $$QMAKE_CXX $$QMAKE_CXXFLAGS -dM -E -o ${QMAKE_FILE_OUT} ${QMAKE_FILE_IN}
|
||||
else:intel_icl: moc_predefs.commands = $$QMAKE_CXX $$QMAKE_CXXFLAGS -QdM -P -Fi${QMAKE_FILE_OUT} ${QMAKE_FILE_IN}
|
||||
else:msvc {
|
||||
moc_predefs.commands += $$QMAKE_CXX -Bx$$shell_path($$[QT_INSTALL_BINS/get]/qmake) $$QMAKE_CXXFLAGS -E ${QMAKE_FILE_IN} 2>NUL >${QMAKE_FILE_OUT}
|
||||
moc_predefs.commands += $$QMAKE_CXX -Bx$$shell_quote($$shell_path($$[QT_INSTALL_BINS/get]/qmake)) $$QMAKE_CXXFLAGS -E ${QMAKE_FILE_IN} 2>NUL >${QMAKE_FILE_OUT}
|
||||
} else: error("Oops, I messed up")
|
||||
moc_predefs.output = $$MOC_DIR/moc_predefs.h
|
||||
moc_predefs.input = MOC_PREDEF_FILE
|
||||
|
28
mkspecs/features/qmake_use.prf
Normal file
28
mkspecs/features/qmake_use.prf
Normal file
@ -0,0 +1,28 @@
|
||||
suffix =
|
||||
for(ever) {
|
||||
QMAKE_USE$${suffix} = $$unique(QMAKE_USE$${suffix})
|
||||
for (use, QMAKE_USE$${suffix}) {
|
||||
use = $$split(use, /)
|
||||
name = $$take_first(use)
|
||||
nu = $$upper($$name)
|
||||
debug: \
|
||||
libs = $$eval(QMAKE_LIBS_$${nu}_DEBUG)
|
||||
else: \
|
||||
libs = $$eval(QMAKE_LIBS_$${nu}_RELEASE)
|
||||
libs += $$eval(QMAKE_LIBS_$$nu)
|
||||
defines = $$eval(QMAKE_DEFINES_$${nu})
|
||||
includes = $$eval(QMAKE_INCDIR_$${nu})
|
||||
|
||||
isEmpty(libs):isEmpty(defines):isEmpty(includes): \
|
||||
error("Library '$$name' is not defined.")
|
||||
|
||||
!contains(use, nolink): \
|
||||
LIBS$${suffix} += $$libs
|
||||
!contains(use, linkonly) {
|
||||
DEFINES += $$defines
|
||||
INCLUDEPATH += $$includes
|
||||
}
|
||||
}
|
||||
!isEmpty(suffix): break()
|
||||
suffix = "_PRIVATE"
|
||||
}
|
@ -1,3 +1,3 @@
|
||||
qtConfig(system-freetype) {
|
||||
LIBS_PRIVATE += -lfreetype
|
||||
QMAKE_USE_PRIVATE += freetype/linkonly
|
||||
}
|
||||
|
@ -1,10 +1,6 @@
|
||||
CONFIG += qpa/basicunixfontdatabase
|
||||
qtConfig(fontconfig) {
|
||||
DEFINES += Q_FONTCONFIGDATABASE
|
||||
LIBS_PRIVATE += -lfontconfig
|
||||
} else:!android {
|
||||
fonts.path = $$[QT_INSTALL_LIBS]/fonts
|
||||
fonts.files = $$QT_SOURCE_TREE/lib/fonts/*
|
||||
INSTALLS += fonts
|
||||
QMAKE_USE_PRIVATE += fontconfig/linkonly
|
||||
}
|
||||
|
||||
|
@ -245,18 +245,25 @@ defineTest(qtConfParseCommandLine) {
|
||||
} else: contains(c, "^--?(disable|no)-(.*)") {
|
||||
opt = $$replace(c, "^--?(disable|no)-(.*)", "\\2")
|
||||
val = no
|
||||
} else: contains(c, "^--?qt-(.*)") {
|
||||
opt = $$replace(c, "^--?qt-(.*)", "\\1")
|
||||
val = qt
|
||||
} else: contains(c, "^--?system-(.*)") {
|
||||
opt = $$replace(c, "^--?system-(.*)", "\\1")
|
||||
val = system
|
||||
} else: contains(c, "^--?([^-].*)=(.*)") {
|
||||
opt = $$replace(c, "^--?([^-].*)=(.*)", "\\1")
|
||||
val = $$replace(c, "^--?([^-].*)=(.*)", "\\2")
|
||||
} else: contains(c, "^--?([^-].*)") {
|
||||
opt = $$replace(c, "^--?([^-].*)", "\\1")
|
||||
} else: contains(c, "^--([^=]+)=(.*)") {
|
||||
opt = $$replace(c, "^--?([^=]+)=(.*)", "\\1")
|
||||
val = $$replace(c, "^--?([^=]+)=(.*)", "\\2")
|
||||
} else: contains(c, "^--(.*)") {
|
||||
opt = $$replace(c, "^--(.*)", "\\1")
|
||||
val = yes
|
||||
} else: contains(c, "^-(.*)") {
|
||||
opt = $$replace(c, "^-(.*)", "\\1")
|
||||
val =
|
||||
for (cc, allConfigs) {
|
||||
type = $$eval($${cc}.commandline.options.$${opt})
|
||||
!isEmpty(type): break()
|
||||
type = $$eval($${cc}.commandline.options.$${opt}.type)
|
||||
!isEmpty(type): break()
|
||||
}
|
||||
isEmpty(type):contains(opt, "(qt|system)-.*") {
|
||||
val = $$replace(opt, "(qt|system)-(.*)", "\\1")
|
||||
opt = $$replace(opt, "(qt|system)-(.*)", "\\2")
|
||||
}
|
||||
} else {
|
||||
qtConfAddError("Invalid command line parameter '$$c'.")
|
||||
return()
|
||||
@ -468,8 +475,6 @@ defineTest(qtConfLibrary_inline) {
|
||||
!isEmpty(prefix) {
|
||||
$${1}.includedir = $$prefix/include
|
||||
export($${1}.includedir)
|
||||
$${1}.cflags = -I$$prefix/include
|
||||
export($${1}.cflags)
|
||||
$${1}.libs = "-L$$prefix/lib $$eval($${1}.libs)"
|
||||
export($${1}.libs)
|
||||
}
|
||||
@ -486,8 +491,6 @@ defineTest(qtConfLibrary_makeSpec) {
|
||||
|
||||
$${1}.includedir = "$$val_escape(QMAKE_INCDIR_$$spec)"
|
||||
export($${1}.includedir)
|
||||
$${1}.cflags = "$$val_escape(QMAKE_CFLAGS_$$spec)"
|
||||
export($${1}.cflags)
|
||||
libs =
|
||||
for (l, QMAKE_LIBDIR_$$spec): \
|
||||
libs += -L$$l
|
||||
@ -515,15 +518,8 @@ defineTest(qtConfLibrary_pkgConfig) {
|
||||
qtRunLoggedCommand("$$pkg_config --modversion $$args", version)|return(false)
|
||||
qtRunLoggedCommand("$$pkg_config --libs-only-L --libs-only-l $$args", $${1}.libs)|return(false)
|
||||
qtRunLoggedCommand("$$pkg_config --cflags $$args", $${1}.cflags)|return(false)
|
||||
qtRunLoggedCommand("$$pkg_config --cflags-only-I $$args", includes)|return(false)
|
||||
eval(includes = $$includes)
|
||||
includes ~= s/^-I//g
|
||||
$${1}.includedir = "$$val_escape(includes)"
|
||||
version ~= s/[^0-9.].*$//
|
||||
$${1}.version = $$first(version)
|
||||
export($${1}.libs)
|
||||
export($${1}.cflags)
|
||||
export($${1}.includedir)
|
||||
export($${1}.version)
|
||||
return(true)
|
||||
}
|
||||
@ -555,6 +551,9 @@ defineReplace(qtConfLibraryArgs) {
|
||||
includedir = $$eval($${1}.includedir)
|
||||
!isEmpty(includedir): \
|
||||
qmake_args += $$system_quote(INCLUDEPATH *= $$includedir)
|
||||
cflags = $$eval($${1}.cflags)
|
||||
!isEmpty(cflags): \
|
||||
qmake_args += $$system_quote(QMAKE_CFLAGS += $$cflags) $$system_quote(QMAKE_CXXFLAGS += $$cflags)
|
||||
return($$qmake_args)
|
||||
}
|
||||
|
||||
@ -581,12 +580,31 @@ defineTest(qtConfExportLibrary) {
|
||||
eval(includes = $$eval($${1}.includedir))
|
||||
version = $$eval($${1}.version)
|
||||
|
||||
# Split $$cflags into stuff that goes into DEFINES, INCLUDEPATH, and other stuff.
|
||||
defines =
|
||||
ignored =
|
||||
for (i, cflags) {
|
||||
contains(i, "-I.*") {
|
||||
i ~= s/^-I//
|
||||
includes += $$i
|
||||
} else: contains(i, "-D.*") {
|
||||
i ~= s/^-D//
|
||||
defines += $$i
|
||||
} else {
|
||||
# Sometimes, pkg-config files or *-config scripts include other flags
|
||||
# we really don't need and shouldn't add (pg_config is really bad).
|
||||
ignored += $$i
|
||||
}
|
||||
}
|
||||
!isEmpty(ignored): \
|
||||
qtConfAddNote("Dropped compiler flags '$$ignored' when detecting library '$$2'.")
|
||||
|
||||
NAME = $$upper($$2)
|
||||
!isEmpty(libs): qtConfOutputVar(assign, $$output, QMAKE_LIBS_$$NAME, $$libs)
|
||||
for (b, $${1}.builds._KEYS_): \
|
||||
qtConfOutputVar(assign, $$output, QMAKE_LIBS_$${NAME}_$$upper($$b), \
|
||||
$$eval($${1}.builds.$${b}))
|
||||
!isEmpty(cflags): qtConfOutputVar(assign, $$output, QMAKE_CFLAGS_$$NAME, $$cflags)
|
||||
!isEmpty(defines): qtConfOutputVar(assign, $$output, QMAKE_DEFINES_$$NAME, $$defines)
|
||||
!isEmpty(includes): qtConfOutputVar(assign, $$output, QMAKE_INCDIR_$$NAME, $$includes)
|
||||
!isEmpty(version) {
|
||||
qtConfOutputVar(assign, $$output, QMAKE_$${NAME}_VERSION, $$version)
|
||||
@ -992,7 +1010,7 @@ defineReplace(qtConfEvaluateSingleExpression) {
|
||||
error("Unknown library object $${lib} in expression '$${1}'.")
|
||||
qtConfHandleLibrary($$lib)
|
||||
!defined($${currentConfig}.libraries.$${lib}.$${var}, var): \
|
||||
var = sources.$$eval($${currentConfig}.libraries.$${lib}.$${source}).$$var
|
||||
var = sources.$$eval($${currentConfig}.libraries.$${lib}.source).$$var
|
||||
result = $$eval($${currentConfig}.libraries.$${lib}.$${var})
|
||||
} else: contains(e, "^features\..*") {
|
||||
feature = $$section(e, ".", 1, 1)
|
||||
|
@ -9,16 +9,6 @@
|
||||
# We mean it.
|
||||
#
|
||||
|
||||
!no_qt_module_warning:!contains(QMAKE_INTERNAL_INCLUDED_FILES, .*qmodule\\.pri) {
|
||||
QMAKE_ACTUAL_PRO_FILE = $$basename(_PRO_FILE_)
|
||||
isEmpty(QMAKE_ACTUAL_PRO_FILE): QMAKE_ACTUAL_PRO_FILE=.pro
|
||||
warning("You should probably load(qt_build_config) first in $$QMAKE_ACTUAL_PRO_FILE for $$TARGET, as the latter also load()s qt_module.")
|
||||
message("Not doing so may lead to qt_module.prf overriding compiler/linker options in your .pro file.")
|
||||
message("Ignore this warning with CONFIG+=no_qt_module_warning if you know what you are doing.")
|
||||
unset(QMAKE_ACTUAL_PRO_FILE)
|
||||
}
|
||||
load(qt_build_config) # loads qmodule.pri if hasn't been loaded already
|
||||
|
||||
isEmpty(MODULE):MODULE = $$section($$list($$basename(_PRO_FILE_)), ., 0, 0)
|
||||
isEmpty(VERSION): VERSION = $$MODULE_VERSION
|
||||
isEmpty(VERSION): error("Module does not define version.")
|
||||
|
@ -51,5 +51,5 @@ equals(QMAKE_HOST.os, Windows) {
|
||||
QMAKE_SH = sh
|
||||
}
|
||||
|
||||
CONFIG = file_copies qt warn_on release link_prl
|
||||
CONFIG = file_copies qmake_use qt warn_on release link_prl
|
||||
QT = core gui
|
||||
|
@ -29,21 +29,6 @@ macx-xcode {
|
||||
QMAKE_MAC_XCODE_SETTINGS += device_family
|
||||
|
||||
ios {
|
||||
# If QMAKE_BUNDLE_DATA contains an asset catalog that includes an
|
||||
# AppIcon.appiconset, we configure Xcode to use it for app icons.
|
||||
for(bundle_data, QMAKE_BUNDLE_DATA) {
|
||||
for(bundle_file, $${bundle_data}.files) {
|
||||
!contains(bundle_file, .*\.xcassets$): next()
|
||||
!exists($$absolute_path($$bundle_file/AppIcon.appiconset, $$_PRO_FILE_PWD_)): next()
|
||||
|
||||
asset_catalog_appicon.name = "ASSETCATALOG_COMPILER_APPICON_NAME"
|
||||
asset_catalog_appicon.value = "AppIcon"
|
||||
QMAKE_MAC_XCODE_SETTINGS += asset_catalog_appicon
|
||||
break()
|
||||
}
|
||||
!isEmpty(asset_catalog_appicon.name): break()
|
||||
}
|
||||
|
||||
# Set up default 4-inch iPhone/iPod launch image so that our apps
|
||||
# support the full screen resolution of those devices.
|
||||
qmake_launch_image = Default-568h@2x.png
|
||||
|
@ -8,4 +8,10 @@ xcodebuild {
|
||||
|
||||
load(resolve_config)
|
||||
|
||||
!macx-xcode:xcodebuild: addExclusiveBuilds(simulator, device)
|
||||
!macx-xcode:xcodebuild {
|
||||
# Switch the order to make sure that the first Makefile target is the right one
|
||||
!qtConfig(simulator_and_device):contains(QMAKE_MAC_SDK, ^$${simulator.sdk}.*): \
|
||||
addExclusiveBuilds(simulator, device)
|
||||
else: \
|
||||
addExclusiveBuilds(device, simulator)
|
||||
}
|
||||
|
@ -18,10 +18,14 @@ QMAKE_EXTRA_COMPILERS =
|
||||
error("Failed to create $$OUT_PWD")
|
||||
|
||||
args =
|
||||
for(arg, QMAKE_ARGS): \
|
||||
args += $$system_quote($$arg)
|
||||
prev_arg =
|
||||
for(arg, QMAKE_ARGS) {
|
||||
!equals(arg, "-spec"):!equals(prev_arg, "-spec"): \
|
||||
args += $$system_quote($$arg)
|
||||
prev_arg = $$arg
|
||||
}
|
||||
|
||||
cmd = "$$QMAKE_QMAKE $$args $$system_quote($$_PRO_FILE_) -spec macx-xcode"
|
||||
cmd = "$$QMAKE_QMAKE $$system_quote($$_PRO_FILE_) -spec macx-xcode $$args"
|
||||
debug(1, "Generating Xcode project in $$OUT_PWD using '$$cmd'")
|
||||
system("cd $$system_quote($$OUT_PWD) && $$cmd")
|
||||
|
||||
|
@ -87,8 +87,9 @@ have_target:!static:if(darwin|!isEmpty(QMAKE_OBJCOPY)) {
|
||||
QMAKE_POST_LINK = $$mkdir_debug_info && $$copy_debug_info && $$strip_debug_info $$QMAKE_POST_LINK
|
||||
} else {
|
||||
link_debug_info = $$QMAKE_OBJCOPY --add-gnu-debuglink=$$shell_target_debug_info $$shell_target
|
||||
chmod_debug_info = chmod -x $$shell_target_debug_info
|
||||
QMAKE_POST_LINK = $$copy_debug_info && $$strip_debug_info && $$link_debug_info && $$chmod_debug_info $$QMAKE_POST_LINK
|
||||
!contains(QMAKE_HOST.os, Windows): \
|
||||
QMAKE_POST_LINK = && chmod -x $$shell_target_debug_info $$QMAKE_POST_LINK
|
||||
QMAKE_POST_LINK = $$copy_debug_info && $$strip_debug_info && $$link_debug_info $$QMAKE_POST_LINK
|
||||
}
|
||||
silent:QMAKE_POST_LINK = @echo creating $@.$$debug_info_suffix && $$QMAKE_POST_LINK
|
||||
|
||||
|
@ -55,141 +55,145 @@
|
||||
else: \
|
||||
manifest_file.output = $$BUILD_DIR/AppxManifest.xml
|
||||
|
||||
# Provide the C-runtime dependency
|
||||
equals(TEMPLATE, "app") {
|
||||
VCLIBS = Microsoft.VCLibs.$$replace(MSVC_VER, \\., ).00
|
||||
winphone: VCLIBS = $${VCLIBS}.Phone
|
||||
CONFIG(debug, debug|release): \
|
||||
VCLIBS = $${VCLIBS}.Debug
|
||||
else: \
|
||||
VCLIBS = $${VCLIBS}
|
||||
contains(MSVC_VER, "14.0"): VCLIBS = "$${VCLIBS}\" MinVersion=\"14.0.0.0\" Publisher=\"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
|
||||
WINRT_MANIFEST.dependencies += $$VCLIBS
|
||||
}
|
||||
|
||||
# Provide default values for required variables
|
||||
isEmpty(WINRT_MANIFEST.target): WINRT_MANIFEST.target = $$TARGET
|
||||
isEmpty(WINRT_MANIFEST.identity) {
|
||||
# Reuse the existing UUID if possible
|
||||
UUID_CACHE = $$OUT_PWD/.qmake.winrt_uuid_$$TARGET
|
||||
exists($$UUID_CACHE) {
|
||||
include($$UUID_CACHE)
|
||||
} else {
|
||||
WINRT_UUID = $$system(uuidgen)
|
||||
isEmpty(WINRT_UUID): error("Unable to generate a UUID. Make sure uuidgen is in your PATH.")
|
||||
WINRT_UUID = "WINRT_MANIFEST.identity = $$WINRT_UUID"
|
||||
write_file($$UUID_CACHE, WINRT_UUID)|error("Unable to write the UUID cache; aborting.")
|
||||
eval($$WINRT_UUID)
|
||||
!contains(WINRT_MANIFEST.CONFIG, "verbatim") {
|
||||
# Provide the C-runtime dependency
|
||||
equals(TEMPLATE, "app") {
|
||||
VCLIBS = Microsoft.VCLibs.$$replace(MSVC_VER, \\., ).00
|
||||
winphone: VCLIBS = $${VCLIBS}.Phone
|
||||
CONFIG(debug, debug|release): \
|
||||
VCLIBS = $${VCLIBS}.Debug
|
||||
else: \
|
||||
VCLIBS = $${VCLIBS}
|
||||
contains(MSVC_VER, "14.0"): VCLIBS = "$${VCLIBS}\" MinVersion=\"14.0.0.0\" Publisher=\"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
|
||||
WINRT_MANIFEST.dependencies += $$VCLIBS
|
||||
}
|
||||
}
|
||||
isEmpty(WINRT_MANIFEST.name): WINRT_MANIFEST.name = $$TARGET
|
||||
isEmpty(WINRT_MANIFEST.architecture): WINRT_MANIFEST.architecture = $$VCPROJ_ARCH
|
||||
isEmpty(WINRT_MANIFEST.version): WINRT_MANIFEST.version = 1.0.0.0
|
||||
isEmpty(WINRT_MANIFEST.publisher): WINRT_MANIFEST.publisher = Default publisher display name
|
||||
isEmpty(WINRT_MANIFEST.publisherid): WINRT_MANIFEST.publisherid = CN=$$(USERNAME)
|
||||
isEmpty(WINRT_MANIFEST.phone_product_id): WINRT_MANIFEST.phone_product_id = $$WINRT_MANIFEST.identity
|
||||
isEmpty(WINRT_MANIFEST.phone_publisher_id): WINRT_MANIFEST.phone_publisher_id = 00000000-0000-0000-0000-000000000000
|
||||
isEmpty(WINRT_MANIFEST.description): WINRT_MANIFEST.description = Default package description
|
||||
isEmpty(WINRT_MANIFEST.background): WINRT_MANIFEST.background = green
|
||||
isEmpty(WINRT_MANIFEST.foreground): WINRT_MANIFEST.foreground = light
|
||||
isEmpty(WINRT_MANIFEST.default_language): WINRT_MANIFEST.default_language = en
|
||||
*-msvc2015 {
|
||||
isEmpty(WINRT_MANIFEST.minVersion): WINRT_MANIFEST.minVersion = $$(UCRTVersion)
|
||||
isEmpty(WINRT_MANIFEST.minVersion): error("No UCRTVersion found in environment."))
|
||||
isEmpty(WINRT_MANIFEST.maxVersionTested): WINRT_MANIFEST.maxVersionTested = $$WINRT_MANIFEST.minVersion
|
||||
}
|
||||
|
||||
INDENT = "$$escape_expand(\\r\\n) "
|
||||
|
||||
VS_XML_NAMESPACE = "m2"
|
||||
winphone: VS_XML_NAMESPACE = "m3"
|
||||
WINRT_MANIFEST.rotation_preference = $$unique(WINRT_MANIFEST.rotation_preference)
|
||||
!isEmpty(WINRT_MANIFEST.rotation_preference) {
|
||||
MANIFEST_ROTATION += "<$${VS_XML_NAMESPACE}:InitialRotationPreference>"
|
||||
for(ROTATION, WINRT_MANIFEST.rotation_preference): \
|
||||
MANIFEST_ROTATION += " <$${VS_XML_NAMESPACE}:Rotation Preference=\"$$ROTATION\" />"
|
||||
MANIFEST_ROTATION += "</$${VS_XML_NAMESPACE}:InitialRotationPreference>"
|
||||
|
||||
WINRT_MANIFEST.rotation_preference = $$join(MANIFEST_ROTATION, $$INDENT, $$INDENT)
|
||||
}
|
||||
|
||||
INDENT = "$$escape_expand(\\r\\n) "
|
||||
|
||||
# All Windows 10 applications need to have internetClient. It is also not marked as additional
|
||||
# capability anymore and is assumed to be standard.
|
||||
*-msvc2015: WINRT_MANIFEST.capabilities += internetClient
|
||||
|
||||
contains(WINRT_MANIFEST.capabilities, defaults) {
|
||||
WINRT_MANIFEST.capabilities -= defaults
|
||||
WINRT_MANIFEST.capabilities += $$WINRT_MANIFEST.capabilities_default
|
||||
}
|
||||
|
||||
contains(WINRT_MANIFEST.capabilities_device, defaults) {
|
||||
WINRT_MANIFEST.capabilities_device -= defaults
|
||||
WINRT_MANIFEST.capabilities_device += $$WINRT_MANIFEST.capabilities_device_default
|
||||
}
|
||||
|
||||
# Capabilities are given as a string list and may change with the configuration (network, sensors, etc.)
|
||||
WINRT_MANIFEST.capabilities = $$unique(WINRT_MANIFEST.capabilities)
|
||||
WINRT_MANIFEST.capabilities_device = $$unique(WINRT_MANIFEST.capabilities_device)
|
||||
!isEmpty(WINRT_MANIFEST.capabilities)|!isEmpty(WINRT_MANIFEST.capabilities_device) {
|
||||
MANIFEST_CAPABILITIES += "<Capabilities>"
|
||||
for(CAPABILITY, WINRT_MANIFEST.capabilities): \
|
||||
MANIFEST_CAPABILITIES += " <Capability Name=\"$$CAPABILITY\" />"
|
||||
for(CAPABILITY, WINRT_MANIFEST.capabilities_device): \
|
||||
MANIFEST_CAPABILITIES += " <DeviceCapability Name=\"$$CAPABILITY\" />"
|
||||
MANIFEST_CAPABILITIES += "</Capabilities>"
|
||||
|
||||
WINRT_MANIFEST.capabilities = $$join(MANIFEST_CAPABILITIES, $$INDENT, $$INDENT)
|
||||
}
|
||||
|
||||
# Dependencies are given as a string list. The CRT dependency is added automatically above.
|
||||
# For MSVC2015 the dependencies are added in conjunction with TargetDeviceFamily
|
||||
# Due to the hard coded dependency on "Windows.Universal" the <Dependencies> tag
|
||||
# is already inside the MSVC2015 manifest.
|
||||
WINRT_MANIFEST.dependencies = $$unique(WINRT_MANIFEST.dependencies)
|
||||
!isEmpty(WINRT_MANIFEST.dependencies) {
|
||||
*-msvc2013: MANIFEST_DEPENDENCIES += "<Dependencies>"
|
||||
for(DEPENDENCY, WINRT_MANIFEST.dependencies): \
|
||||
MANIFEST_DEPENDENCIES += " <PackageDependency Name=\"$$DEPENDENCY\" />"
|
||||
*-msvc2013: MANIFEST_DEPENDENCIES += "</Dependencies>"
|
||||
|
||||
WINRT_MANIFEST.dependencies = $$join(MANIFEST_DEPENDENCIES, $$INDENT, $$INDENT)
|
||||
}
|
||||
|
||||
# Provide default icons where needed
|
||||
isEmpty(WINRT_ASSETS_PATH): WINRT_ASSETS_PATH = $$[QT_HOST_DATA/get]/mkspecs/common/winrt_winphone/assets
|
||||
TEMPLATE_CONTENTS = $$cat($$WINRT_MANIFEST, lines)
|
||||
ICONS_FOUND = $$find(TEMPLATE_CONTENTS, \\\$\\\$\\{WINRT_MANIFEST\\.(logo|tile)_)
|
||||
ICONS_FOUND ~= s/.*\\\$\\\$\\{WINRT_MANIFEST\\.((logo|tile)_[^\}]+)\\}.*/\\1/g
|
||||
for (ICON_NAME, ICONS_FOUND) {
|
||||
ICON_FILE = $$eval(WINRT_MANIFEST.$$ICON_NAME)
|
||||
isEmpty(ICON_FILE) {
|
||||
equals(ICON_NAME, "logo_310x150"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_wide)
|
||||
else: equals(ICON_NAME, "logo_150x150"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_large)
|
||||
# Windows Phone specifics
|
||||
else: equals(ICON_NAME, "logo_480x800"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_splash)
|
||||
else: equals(ICON_NAME, "logo_71x71"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_medium)
|
||||
else: equals(ICON_NAME, "logo_44x44"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_small)
|
||||
# Windows RT specifics
|
||||
else: equals(ICON_NAME, "logo_620x300"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_splash)
|
||||
else: equals(ICON_NAME, "logo_70x70"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_medium)
|
||||
else: equals(ICON_NAME, "logo_30x30"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_small)
|
||||
# Provide default values for required variables
|
||||
isEmpty(WINRT_MANIFEST.target): WINRT_MANIFEST.target = $$TARGET
|
||||
isEmpty(WINRT_MANIFEST.identity) {
|
||||
# Reuse the existing UUID if possible
|
||||
UUID_CACHE = $$OUT_PWD/.qmake.winrt_uuid_$$TARGET
|
||||
exists($$UUID_CACHE) {
|
||||
include($$UUID_CACHE)
|
||||
} else {
|
||||
WINRT_UUID = $$system(uuidgen)
|
||||
isEmpty(WINRT_UUID): error("Unable to generate a UUID. Make sure uuidgen is in your PATH.")
|
||||
WINRT_UUID = "WINRT_MANIFEST.identity = $$WINRT_UUID"
|
||||
write_file($$UUID_CACHE, WINRT_UUID)|error("Unable to write the UUID cache; aborting.")
|
||||
eval($$WINRT_UUID)
|
||||
}
|
||||
}
|
||||
isEmpty(WINRT_MANIFEST.name): WINRT_MANIFEST.name = $$TARGET
|
||||
isEmpty(WINRT_MANIFEST.architecture): WINRT_MANIFEST.architecture = $$VCPROJ_ARCH
|
||||
isEmpty(WINRT_MANIFEST.version): WINRT_MANIFEST.version = 1.0.0.0
|
||||
isEmpty(WINRT_MANIFEST.publisher): WINRT_MANIFEST.publisher = Default publisher display name
|
||||
isEmpty(WINRT_MANIFEST.publisherid): WINRT_MANIFEST.publisherid = CN=$$(USERNAME)
|
||||
isEmpty(WINRT_MANIFEST.phone_product_id): WINRT_MANIFEST.phone_product_id = $$WINRT_MANIFEST.identity
|
||||
isEmpty(WINRT_MANIFEST.phone_publisher_id): WINRT_MANIFEST.phone_publisher_id = 00000000-0000-0000-0000-000000000000
|
||||
isEmpty(WINRT_MANIFEST.description): WINRT_MANIFEST.description = Default package description
|
||||
isEmpty(WINRT_MANIFEST.background): WINRT_MANIFEST.background = green
|
||||
isEmpty(WINRT_MANIFEST.foreground): WINRT_MANIFEST.foreground = light
|
||||
isEmpty(WINRT_MANIFEST.default_language): WINRT_MANIFEST.default_language = en
|
||||
*-msvc2015 {
|
||||
isEmpty(WINRT_MANIFEST.minVersion): WINRT_MANIFEST.minVersion = $$(UCRTVersion)
|
||||
isEmpty(WINRT_MANIFEST.minVersion): error("No UCRTVersion found in environment."))
|
||||
isEmpty(WINRT_MANIFEST.maxVersionTested): WINRT_MANIFEST.maxVersionTested = $$WINRT_MANIFEST.minVersion
|
||||
}
|
||||
isEmpty(ICON_FILE): ICON_FILE = $$WINRT_ASSETS_PATH/$${ICON_NAME}.png
|
||||
icon_$${ICON_NAME}.input = $$ICON_FILE
|
||||
icon_$${ICON_NAME}.output = $$BUILD_DIR/assets/$$basename(ICON_FILE)
|
||||
icon_$${ICON_NAME}.CONFIG = verbatim
|
||||
QMAKE_SUBSTITUTES += icon_$${ICON_NAME}
|
||||
WINRT_MANIFEST.$${ICON_NAME} = assets/$$basename(ICON_FILE)
|
||||
}
|
||||
|
||||
!contains(TEMPLATE, "vc.*") {
|
||||
winrt_manifest_install.files = $$manifest_file.output
|
||||
winrt_manifest_install.path = $$target.path
|
||||
winrt_assets_install.files = $$BUILD_DIR/assets/*
|
||||
winrt_assets_install.path = $$target.path/assets
|
||||
INSTALLS += winrt_manifest_install winrt_assets_install
|
||||
INDENT = "$$escape_expand(\\r\\n) "
|
||||
|
||||
VS_XML_NAMESPACE = "m2"
|
||||
winphone: VS_XML_NAMESPACE = "m3"
|
||||
WINRT_MANIFEST.rotation_preference = $$unique(WINRT_MANIFEST.rotation_preference)
|
||||
!isEmpty(WINRT_MANIFEST.rotation_preference) {
|
||||
MANIFEST_ROTATION += "<$${VS_XML_NAMESPACE}:InitialRotationPreference>"
|
||||
for(ROTATION, WINRT_MANIFEST.rotation_preference): \
|
||||
MANIFEST_ROTATION += " <$${VS_XML_NAMESPACE}:Rotation Preference=\"$$ROTATION\" />"
|
||||
MANIFEST_ROTATION += "</$${VS_XML_NAMESPACE}:InitialRotationPreference>"
|
||||
|
||||
WINRT_MANIFEST.rotation_preference = $$join(MANIFEST_ROTATION, $$INDENT, $$INDENT)
|
||||
}
|
||||
|
||||
INDENT = "$$escape_expand(\\r\\n) "
|
||||
|
||||
# All Windows 10 applications need to have internetClient. It is also not marked as additional
|
||||
# capability anymore and is assumed to be standard.
|
||||
*-msvc2015: WINRT_MANIFEST.capabilities += internetClient
|
||||
|
||||
contains(WINRT_MANIFEST.capabilities, defaults) {
|
||||
WINRT_MANIFEST.capabilities -= defaults
|
||||
WINRT_MANIFEST.capabilities += $$WINRT_MANIFEST.capabilities_default
|
||||
}
|
||||
|
||||
contains(WINRT_MANIFEST.capabilities_device, defaults) {
|
||||
WINRT_MANIFEST.capabilities_device -= defaults
|
||||
WINRT_MANIFEST.capabilities_device += $$WINRT_MANIFEST.capabilities_device_default
|
||||
}
|
||||
|
||||
# Capabilities are given as a string list and may change with the configuration (network, sensors, etc.)
|
||||
WINRT_MANIFEST.capabilities = $$unique(WINRT_MANIFEST.capabilities)
|
||||
WINRT_MANIFEST.capabilities_device = $$unique(WINRT_MANIFEST.capabilities_device)
|
||||
!isEmpty(WINRT_MANIFEST.capabilities)|!isEmpty(WINRT_MANIFEST.capabilities_device) {
|
||||
MANIFEST_CAPABILITIES += "<Capabilities>"
|
||||
for(CAPABILITY, WINRT_MANIFEST.capabilities): \
|
||||
MANIFEST_CAPABILITIES += " <Capability Name=\"$$CAPABILITY\" />"
|
||||
for(CAPABILITY, WINRT_MANIFEST.capabilities_device): \
|
||||
MANIFEST_CAPABILITIES += " <DeviceCapability Name=\"$$CAPABILITY\" />"
|
||||
MANIFEST_CAPABILITIES += "</Capabilities>"
|
||||
|
||||
WINRT_MANIFEST.capabilities = $$join(MANIFEST_CAPABILITIES, $$INDENT, $$INDENT)
|
||||
}
|
||||
|
||||
# Dependencies are given as a string list. The CRT dependency is added automatically above.
|
||||
# For MSVC2015 the dependencies are added in conjunction with TargetDeviceFamily
|
||||
# Due to the hard coded dependency on "Windows.Universal" the <Dependencies> tag
|
||||
# is already inside the MSVC2015 manifest.
|
||||
WINRT_MANIFEST.dependencies = $$unique(WINRT_MANIFEST.dependencies)
|
||||
!isEmpty(WINRT_MANIFEST.dependencies) {
|
||||
*-msvc2013: MANIFEST_DEPENDENCIES += "<Dependencies>"
|
||||
for(DEPENDENCY, WINRT_MANIFEST.dependencies): \
|
||||
MANIFEST_DEPENDENCIES += " <PackageDependency Name=\"$$DEPENDENCY\" />"
|
||||
*-msvc2013: MANIFEST_DEPENDENCIES += "</Dependencies>"
|
||||
|
||||
WINRT_MANIFEST.dependencies = $$join(MANIFEST_DEPENDENCIES, $$INDENT, $$INDENT)
|
||||
}
|
||||
|
||||
# Provide default icons where needed
|
||||
isEmpty(WINRT_ASSETS_PATH): WINRT_ASSETS_PATH = $$[QT_HOST_DATA/get]/mkspecs/common/winrt_winphone/assets
|
||||
TEMPLATE_CONTENTS = $$cat($$WINRT_MANIFEST, lines)
|
||||
ICONS_FOUND = $$find(TEMPLATE_CONTENTS, \\\$\\\$\\{WINRT_MANIFEST\\.(logo|tile)_)
|
||||
ICONS_FOUND ~= s/.*\\\$\\\$\\{WINRT_MANIFEST\\.((logo|tile)_[^\}]+)\\}.*/\\1/g
|
||||
for (ICON_NAME, ICONS_FOUND) {
|
||||
ICON_FILE = $$eval(WINRT_MANIFEST.$$ICON_NAME)
|
||||
isEmpty(ICON_FILE) {
|
||||
equals(ICON_NAME, "logo_310x150"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_wide)
|
||||
else: equals(ICON_NAME, "logo_150x150"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_large)
|
||||
# Windows Phone specifics
|
||||
else: equals(ICON_NAME, "logo_480x800"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_splash)
|
||||
else: equals(ICON_NAME, "logo_71x71"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_medium)
|
||||
else: equals(ICON_NAME, "logo_44x44"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_small)
|
||||
# Windows RT specifics
|
||||
else: equals(ICON_NAME, "logo_620x300"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_splash)
|
||||
else: equals(ICON_NAME, "logo_70x70"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_medium)
|
||||
else: equals(ICON_NAME, "logo_30x30"): ICON_FILE = $$eval(WINRT_MANIFEST.logo_small)
|
||||
}
|
||||
isEmpty(ICON_FILE): ICON_FILE = $$WINRT_ASSETS_PATH/$${ICON_NAME}.png
|
||||
icon_$${ICON_NAME}.input = $$ICON_FILE
|
||||
icon_$${ICON_NAME}.output = $$BUILD_DIR/assets/$$basename(ICON_FILE)
|
||||
icon_$${ICON_NAME}.CONFIG = verbatim
|
||||
QMAKE_SUBSTITUTES += icon_$${ICON_NAME}
|
||||
WINRT_MANIFEST.$${ICON_NAME} = assets/$$basename(ICON_FILE)
|
||||
}
|
||||
|
||||
!contains(TEMPLATE, "vc.*") {
|
||||
winrt_manifest_install.files = $$manifest_file.output
|
||||
winrt_manifest_install.path = $$target.path
|
||||
winrt_assets_install.files = $$BUILD_DIR/assets/*
|
||||
winrt_assets_install.path = $$target.path/assets
|
||||
INSTALLS += winrt_manifest_install winrt_assets_install
|
||||
}
|
||||
} else {
|
||||
manifest_file.CONFIG += verbatim
|
||||
}
|
||||
|
||||
QMAKE_SUBSTITUTES += manifest_file
|
||||
|
@ -7,9 +7,6 @@ QMAKE_PLATFORM = haiku
|
||||
|
||||
include(../common/unix.conf)
|
||||
|
||||
# Choose haiku QPA Plugin as default
|
||||
QT_QPA_DEFAULT_PLATFORM = haiku
|
||||
|
||||
QMAKE_LIBS =
|
||||
QMAKE_INCDIR =
|
||||
QMAKE_LIBDIR =
|
||||
|
@ -50,6 +50,7 @@ QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
|
||||
QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
|
||||
QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
|
||||
QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
|
||||
QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO = $$QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO
|
||||
QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
|
||||
QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
|
||||
QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
|
||||
|
@ -99,15 +99,12 @@ CPPFLAGS = -g $(EXTRA_CPPFLAGS) \
|
||||
-I$(QMKSRC)/generators/mac -I$(QMKSRC)/generators/integrity \
|
||||
-I$(INC_PATH) -I$(INC_PATH)/QtCore \
|
||||
-I$(INC_PATH)/QtCore/$(QT_VERSION) -I$(INC_PATH)/QtCore/$(QT_VERSION)/QtCore \
|
||||
-I$(BUILD_PATH)/src/corelib/global -DHAVE_QCONFIG_CPP \
|
||||
-I$(BUILD_PATH)/src/corelib/global \
|
||||
-I$(QMAKESPEC) \
|
||||
-I$(SOURCE_PATH)/tools/shared \
|
||||
-DQT_VERSION_STR=\"$(QT_VERSION)\" -DQT_VERSION_MAJOR=$(QT_MAJOR_VERSION) -DQT_VERSION_MINOR=$(QT_MINOR_VERSION) -DQT_VERSION_PATCH=$(QT_PATCH_VERSION) \
|
||||
-DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DPROEVALUATOR_FULL \
|
||||
-DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_COMPRESS \
|
||||
-DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM \
|
||||
-DQT_NO_FOREACH \
|
||||
-DQT_CRYPTOGRAPHICHASH_ONLY_SHA1 -DQT_JSON_READONLY -DQT_NO_STANDARDPATHS
|
||||
-DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DPROEVALUATOR_FULL \
|
||||
-DQT_NO_FOREACH
|
||||
|
||||
CXXFLAGS = $(EXTRA_CXXFLAGS) $(CPPFLAGS)
|
||||
|
||||
|
@ -40,15 +40,12 @@ CFLAGS_BARE = -c -Fo./ -Fdqmake.pdb \
|
||||
$(CFLAGS_EXTRA) \
|
||||
-I$(QMKSRC) -I$(QMKSRC)\library -I$(QMKSRC)\generators -I$(QMKSRC)\generators\unix -I$(QMKSRC)\generators\win32 -I$(QMKSRC)\generators\mac -I$(QMKSRC)\generators\integrity \
|
||||
-I$(INC_PATH) -I$(INC_PATH)\QtCore -I$(INC_PATH)\QtCore\$(QT_VERSION) -I$(INC_PATH)\QtCore\$(QT_VERSION)\QtCore \
|
||||
-I$(BUILD_PATH)\src\corelib\global -DHAVE_QCONFIG_CPP \
|
||||
-I$(BUILD_PATH)\src\corelib\global \
|
||||
-I$(SOURCE_PATH)\mkspecs\$(QMAKESPEC) \
|
||||
-I$(SOURCE_PATH)\tools\shared \
|
||||
-DQT_VERSION_STR=\"$(QT_VERSION)\" -DQT_VERSION_MAJOR=$(QT_MAJOR_VERSION) -DQT_VERSION_MINOR=$(QT_MINOR_VERSION) -DQT_VERSION_PATCH=$(QT_PATCH_VERSION) \
|
||||
-DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DPROEVALUATOR_FULL \
|
||||
-DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_COMPRESS \
|
||||
-DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM \
|
||||
-DQT_NO_FOREACH \
|
||||
-DUNICODE -DQT_CRYPTOGRAPHICHASH_ONLY_SHA1 -DQT_JSON_READONLY -DQT_NO_STANDARDPATHS
|
||||
-DQT_NO_FOREACH -DUNICODE
|
||||
CFLAGS = $(CFLAGS_PCH) $(CFLAGS_BARE) $(CFLAGS)
|
||||
|
||||
CXXFLAGS_BARE = $(CFLAGS_BARE)
|
||||
|
@ -1915,7 +1915,7 @@ ProjectBuilderMakefileGenerator::pbuilderVersion() const
|
||||
CFStringRef str = CFStringRef(CFBundleGetValueForInfoDictionaryKey(bundle,
|
||||
CFSTR("CFBundleShortVersionString")));
|
||||
if (str) {
|
||||
QStringList versions = QCFString::toQString(str).split(QLatin1Char('.'));
|
||||
QStringList versions = QString::fromCFString(str).split(QLatin1Char('.'));
|
||||
int versionMajor = versions.at(0).toInt();
|
||||
int versionMinor = versions.at(1).toInt();
|
||||
if (versionMajor >= 3) {
|
||||
|
@ -208,9 +208,9 @@ inline QString operator+(const QString &one, const ProString &two)
|
||||
{ return ProString(one) + two; }
|
||||
|
||||
inline QString operator+(const ProString &one, const char *two)
|
||||
{ QString ret = one.toQStringRef() + two; ret.detach(); return ret; }
|
||||
{ QString ret = one.toQStringRef() + QLatin1String(two); ret.detach(); return ret; }
|
||||
inline QString operator+(const char *one, const ProString &two)
|
||||
{ QString ret = one + two.toQStringRef(); ret.detach(); return ret; }
|
||||
{ QString ret = QLatin1String(one) + two.toQStringRef(); ret.detach(); return ret; }
|
||||
inline QString operator+(const ProString &one, QChar two)
|
||||
{ return one.toQStringRef() + two; }
|
||||
inline QString operator+(QChar one, const ProString &two)
|
||||
|
@ -468,7 +468,9 @@ QByteArray QMakeEvaluator::getCommandOutput(const QString &args, int *exitCode)
|
||||
if (!errout.isEmpty()) {
|
||||
if (errout.endsWith('\n'))
|
||||
errout.chop(1);
|
||||
m_handler->message(QMakeHandler::EvalError, QString::fromLocal8Bit(errout));
|
||||
m_handler->message(
|
||||
QMakeHandler::EvalError | (m_cumulative ? QMakeHandler::CumulativeEvalMessage : 0),
|
||||
QString::fromLocal8Bit(errout));
|
||||
}
|
||||
# endif
|
||||
out = proc.readAllStandardOutput();
|
||||
|
@ -1024,21 +1024,8 @@ void QMakeEvaluator::loadDefaults()
|
||||
if (GetComputerName(name, &name_length))
|
||||
vars[ProKey("QMAKE_HOST.name")] << ProString(QString::fromWCharArray(name));
|
||||
|
||||
QSysInfo::WinVersion ver = QSysInfo::WindowsVersion;
|
||||
vars[ProKey("QMAKE_HOST.version")] << ProString(QString::number(ver));
|
||||
ProString verStr;
|
||||
switch (ver) {
|
||||
case QSysInfo::WV_Me: verStr = ProString("WinMe"); break;
|
||||
case QSysInfo::WV_95: verStr = ProString("Win95"); break;
|
||||
case QSysInfo::WV_98: verStr = ProString("Win98"); break;
|
||||
case QSysInfo::WV_NT: verStr = ProString("WinNT"); break;
|
||||
case QSysInfo::WV_2000: verStr = ProString("Win2000"); break;
|
||||
case QSysInfo::WV_2003: verStr = ProString("Win2003"); break;
|
||||
case QSysInfo::WV_XP: verStr = ProString("WinXP"); break;
|
||||
case QSysInfo::WV_VISTA: verStr = ProString("WinVista"); break;
|
||||
default: verStr = ProString("Unknown"); break;
|
||||
}
|
||||
vars[ProKey("QMAKE_HOST.version_string")] << verStr;
|
||||
vars[ProKey("QMAKE_HOST.version")] << ProString(QSysInfo::kernelVersion());
|
||||
vars[ProKey("QMAKE_HOST.version_string")] << ProString(QSysInfo::productVersion());
|
||||
|
||||
SYSTEM_INFO info;
|
||||
GetSystemInfo(&info);
|
||||
@ -2037,7 +2024,7 @@ QMakeEvaluator::VisitReturn QMakeEvaluator::evaluateFileInto(
|
||||
void QMakeEvaluator::message(int type, const QString &msg) const
|
||||
{
|
||||
if (!m_skipLevel)
|
||||
m_handler->message(type, msg,
|
||||
m_handler->message(type | (m_cumulative ? QMakeHandler::CumulativeEvalMessage : 0), msg,
|
||||
m_current.line ? m_current.pro->fileName() : QString(),
|
||||
m_current.line != 0xffff ? m_current.line : -1);
|
||||
}
|
||||
|
@ -60,6 +60,7 @@ bool QMakeVfs::writeFile(const QString &fn, QIODevice::OpenMode mode, bool exe,
|
||||
else
|
||||
*cont = contents;
|
||||
Q_UNUSED(errStr)
|
||||
Q_UNUSED(exe)
|
||||
return true;
|
||||
#else
|
||||
QFileInfo qfi(fn);
|
||||
|
@ -151,11 +151,7 @@ bootstrap { #Qt code
|
||||
LFLAGS += -lcpp
|
||||
}
|
||||
|
||||
DEFINES += \
|
||||
QT_BOOTSTRAPPED \
|
||||
QT_NO_TEXTCODEC QT_NO_UNICODETABLES QT_NO_COMPONENT QT_NO_COMPRESS \
|
||||
QT_NO_THREAD QT_NO_QOBJECT QT_NO_GEOM_VARIANT QT_NO_DATASTREAM \
|
||||
QT_CRYPTOGRAPHICHASH_ONLY_SHA1 QT_JSON_READONLY QT_NO_STANDARDPATHS
|
||||
DEFINES += QT_BOOTSTRAPPED
|
||||
|
||||
INCLUDEPATH += \
|
||||
$$QT.core.includes $$QT.core_private.includes \
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
load(qt_parts)
|
||||
|
||||
SUBDIRS += qmake/qmake-aux.pro
|
||||
SUBDIRS += qmake/qmake-aux.pro doc
|
||||
|
||||
cross_compile: CONFIG += nostrip
|
||||
|
||||
@ -84,10 +84,6 @@ mkspecs.files = \
|
||||
mkspecs.files -= $$PWD/mkspecs/modules $$PWD/mkspecs/modules-inst
|
||||
INSTALLS += mkspecs
|
||||
|
||||
global_docs.files = $$PWD/doc/global
|
||||
global_docs.path = $$[QT_INSTALL_DOCS]
|
||||
INSTALLS += global_docs
|
||||
|
||||
OTHER_FILES += \
|
||||
configure \
|
||||
header.BSD \
|
||||
|
4
src/3rdparty/atspi2/xml/Cache.xml
vendored
4
src/3rdparty/atspi2/xml/Cache.xml
vendored
@ -9,12 +9,12 @@
|
||||
|
||||
<signal name="AddAccessible">
|
||||
<arg name="nodeAdded" type="((so)(so)a(so)assusau)"/>
|
||||
<annotation name="org.qtproject.QtDBus.QtTypeName.In0" value="QSpiAccessibleCacheItem"/>
|
||||
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="QSpiAccessibleCacheItem"/>
|
||||
</signal>
|
||||
|
||||
<signal name="RemoveAccessible">
|
||||
<arg name="nodeRemoved" type="(so)"/>
|
||||
<annotation name="org.qtproject.QtDBus.QtTypeName.In0" value="QSpiObjectReference"/>
|
||||
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="QSpiObjectReference"/>
|
||||
</signal>
|
||||
|
||||
</interface>
|
||||
|
3
src/3rdparty/freetype_dependency.pri
vendored
3
src/3rdparty/freetype_dependency.pri
vendored
@ -1,6 +1,5 @@
|
||||
qtConfig(system-freetype) {
|
||||
# pull in the proper freetype2 include directory
|
||||
include($$QT_SOURCE_TREE/config.tests/unix/freetype/freetype.pri)
|
||||
QMAKE_USE_PRIVATE += freetype/nolink
|
||||
} else: qtConfig(freetype) {
|
||||
INCLUDEPATH += $$PWD/freetype/include
|
||||
LIBS_PRIVATE += -L$$QT_BUILD_TREE/lib -lqtfreetype$$qtPlatformTargetSuffix()
|
||||
|
4
src/3rdparty/sha3/KeccakF-1600-interface.h
vendored
4
src/3rdparty/sha3/KeccakF-1600-interface.h
vendored
@ -14,7 +14,11 @@ http://creativecommons.org/publicdomain/zero/1.0/
|
||||
#ifndef _KeccakPermutationInterface_h_
|
||||
#define _KeccakPermutationInterface_h_
|
||||
|
||||
#include <private/qglobal_p.h>
|
||||
|
||||
#if QT_CONFIG(sha3_fast)
|
||||
#include "KeccakF-1600-int-set.h"
|
||||
#endif
|
||||
|
||||
static void KeccakInitialize( void );
|
||||
static void KeccakInitializeState(unsigned char *state);
|
||||
|
2
src/3rdparty/xkbcommon.pri
vendored
2
src/3rdparty/xkbcommon.pri
vendored
@ -4,6 +4,8 @@ INCLUDEPATH += $$PWD/xkbcommon \
|
||||
$$PWD/xkbcommon/src \
|
||||
$$PWD/xkbcommon/src/xkbcomp
|
||||
|
||||
include($$shadowed($$PWD/../gui/qtgui-config.pri))
|
||||
|
||||
DEFINES += DFLT_XKB_CONFIG_ROOT='\\"$$QMAKE_XKB_CONFIG_ROOT\\"'
|
||||
|
||||
### RMLVO names can be overwritten with environmental variables (see libxkbcommon documentation)
|
||||
|
@ -258,16 +258,20 @@ public class QtActivity extends Activity
|
||||
}
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState)
|
||||
{
|
||||
super.onCreate(savedInstanceState);
|
||||
protected void onCreateHook(Bundle savedInstanceState) {
|
||||
m_loader.APPLICATION_PARAMETERS = APPLICATION_PARAMETERS;
|
||||
m_loader.ENVIRONMENT_VARIABLES = ENVIRONMENT_VARIABLES;
|
||||
m_loader.QT_ANDROID_THEMES = QT_ANDROID_THEMES;
|
||||
m_loader.QT_ANDROID_DEFAULT_THEME = QT_ANDROID_DEFAULT_THEME;
|
||||
m_loader.onCreate(savedInstanceState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCreate(Bundle savedInstanceState)
|
||||
{
|
||||
super.onCreate(savedInstanceState);
|
||||
onCreateHook(savedInstanceState);
|
||||
}
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
@Override
|
||||
|
@ -50,11 +50,14 @@ public class QtService extends Service
|
||||
/////////////////////////// Super class calls ////////////////////////////////////
|
||||
/////////////// PLEASE DO NOT CHANGE THE FOLLOWING CODE //////////////////////////
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
protected void onCreateHook() {
|
||||
m_loader.onCreate();
|
||||
}
|
||||
@Override
|
||||
public void onCreate()
|
||||
{
|
||||
super.onCreate();
|
||||
m_loader.onCreate();
|
||||
onCreateHook();
|
||||
}
|
||||
//---------------------------------------------------------------------------
|
||||
|
||||
|
@ -353,6 +353,7 @@
|
||||
},
|
||||
"qeventtransition": {
|
||||
"label": "QEventTransition class",
|
||||
"condition": "features.statemachine",
|
||||
"output": [ "publicFeature" ]
|
||||
},
|
||||
"sharedmemory": {
|
||||
@ -557,6 +558,30 @@
|
||||
"purpose": "Provides a framework for gestures.",
|
||||
"section": "Utilities",
|
||||
"output": [ "publicFeature", "feature" ]
|
||||
},
|
||||
"sha3-fast": {
|
||||
"label": "Speed optimized SHA3",
|
||||
"purpose": "Optimizes SHA3 for speed instead of size.",
|
||||
"section": "Utilities",
|
||||
"output": [ "privateFeature" ]
|
||||
},
|
||||
"timezone": {
|
||||
"label": "QTimeZone",
|
||||
"purpose": "Provides support for timezone handling.",
|
||||
"section": "Utilities",
|
||||
"output": [ "publicFeature" ]
|
||||
},
|
||||
"commandlineparser": {
|
||||
"label": "QCommandlineParser",
|
||||
"purpose": "Provides support for command line parsing.",
|
||||
"section": "Utilities",
|
||||
"output": [ "publicFeature" ]
|
||||
},
|
||||
"topleveldomain": {
|
||||
"label": "QUrl::topLevelDomain()",
|
||||
"description": "Provides support for extracting the top level domain from URLs.",
|
||||
"section": "Utilities",
|
||||
"output": [ "publicFeature" ]
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -1351,10 +1351,16 @@
|
||||
/* Clang can not parse namespaced attributes in C mode, but defines __has_cpp_attribute */
|
||||
# if QT_HAS_CPP_ATTRIBUTE(clang::fallthrough)
|
||||
# define Q_FALLTHROUGH() [[clang::fallthrough]]
|
||||
# elif QT_HAS_CPP_ATTRIBUTE(gnu::fallthrough)
|
||||
# define Q_FALLTHROUGH() [[gnu::fallthrough]]
|
||||
# endif
|
||||
#endif
|
||||
#ifndef Q_FALLTHROUGH
|
||||
# define Q_FALLTHROUGH() (void)0
|
||||
# if defined(Q_CC_GNU) && Q_CC_GNU >= 700
|
||||
# define Q_FALLTHROUGH() __attribute__((fallthrough))
|
||||
# else
|
||||
# define Q_FALLTHROUGH() (void)0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
|
99
src/corelib/global/qconfig-bootstrapped.h
Normal file
99
src/corelib/global/qconfig-bootstrapped.h
Normal file
@ -0,0 +1,99 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2016 The Qt Company Ltd.
|
||||
** Contact: https://www.qt.io/licensing/
|
||||
**
|
||||
** This file is part of the QtCore module of the Qt Toolkit.
|
||||
**
|
||||
** $QT_BEGIN_LICENSE:LGPL$
|
||||
** Commercial License Usage
|
||||
** Licensees holding valid commercial Qt licenses may use this file in
|
||||
** accordance with the commercial license agreement provided with the
|
||||
** Software or, alternatively, in accordance with the terms contained in
|
||||
** a written agreement between you and The Qt Company. For licensing terms
|
||||
** and conditions see https://www.qt.io/terms-conditions. For further
|
||||
** information use the contact form at https://www.qt.io/contact-us.
|
||||
**
|
||||
** GNU Lesser General Public License Usage
|
||||
** Alternatively, this file may be used under the terms of the GNU Lesser
|
||||
** General Public License version 3 as published by the Free Software
|
||||
** Foundation and appearing in the file LICENSE.LGPL3 included in the
|
||||
** packaging of this file. Please review the following information to
|
||||
** ensure the GNU Lesser General Public License version 3 requirements
|
||||
** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
|
||||
**
|
||||
** GNU General Public License Usage
|
||||
** Alternatively, this file may be used under the terms of the GNU
|
||||
** General Public License version 2.0 or (at your option) the GNU General
|
||||
** Public license version 3 or any later version approved by the KDE Free
|
||||
** Qt Foundation. The licenses are as published by the Free Software
|
||||
** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
|
||||
** included in the packaging of this file. Please review the following
|
||||
** information to ensure the GNU General Public License requirements will
|
||||
** be met: https://www.gnu.org/licenses/gpl-2.0.html and
|
||||
** https://www.gnu.org/licenses/gpl-3.0.html.
|
||||
**
|
||||
** $QT_END_LICENSE$
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
//
|
||||
// W A R N I N G
|
||||
// -------------
|
||||
//
|
||||
// This file is not part of the Qt API. It exists purely as an
|
||||
// implementation detail. This header file may change from version to
|
||||
// version without notice, or even be removed.
|
||||
//
|
||||
// We mean it.
|
||||
//
|
||||
// Despite its file name, this really is not a public header.
|
||||
// It is an implementation detail of the private bootstrap library.
|
||||
//
|
||||
|
||||
#if 0
|
||||
// silence syncqt warnings
|
||||
#pragma qt_sync_skip_header_check
|
||||
#pragma qt_sync_stop_processing
|
||||
#endif
|
||||
|
||||
#ifdef QT_BOOTSTRAPPED
|
||||
|
||||
#ifndef QT_NO_EXCEPTIONS
|
||||
#define QT_NO_EXCEPTIONS
|
||||
#endif
|
||||
|
||||
#define QT_NO_USING_NAMESPACE
|
||||
#define QT_NO_DEPRECATED
|
||||
|
||||
#define QT_CRYPTOGRAPHICHASH_ONLY_SHA1
|
||||
#define QT_NO_DATASTREAM
|
||||
#define QT_NO_LIBRARY
|
||||
#define QT_FEATURE_library -1
|
||||
#define QT_NO_QOBJECT
|
||||
#define QT_NO_SYSTEMLOCALE
|
||||
#define QT_NO_THREAD
|
||||
#define QT_FEATURE_timezone -1
|
||||
#define QT_FEATURE_topleveldomain -1
|
||||
#define QT_NO_TRANSLATION
|
||||
#define QT_FEATURE_translation -1
|
||||
#define QT_NO_GEOM_VARIANT
|
||||
|
||||
#if defined(QT_BUILD_QMAKE) || defined(QT_BUILD_CONFIGURE)
|
||||
#define QT_FEATURE_commandlineparser -1
|
||||
#define QT_NO_COMPRESS
|
||||
#define QT_JSON_READONLY
|
||||
#define QT_NO_TEXTCODEC
|
||||
#define QT_FEATURE_textcodec -1
|
||||
#else
|
||||
#define QT_NO_CODECS
|
||||
#define QT_FEATURE_codecs -1
|
||||
#define QT_FEATURE_commandlineparser 1
|
||||
#define QT_FEATURE_textcodec 1
|
||||
#endif
|
||||
|
||||
#if defined(QT_BUILD_QMAKE)
|
||||
#define QT_NO_STANDARDPATHS
|
||||
#endif
|
||||
|
||||
#endif // QT_BOOTSTRAPPED
|
@ -3381,7 +3381,7 @@ Q_GLOBAL_STATIC(AndroidRandomStorage, randomTLS)
|
||||
pseudo random integers to be returned by qrand().
|
||||
|
||||
The sequence of random numbers generated is deterministic per thread. For example,
|
||||
if two threads call qsrand(1) and subsequently calls qrand(), the threads will get
|
||||
if two threads call qsrand(1) and subsequently call qrand(), the threads will get
|
||||
the same random number sequence.
|
||||
|
||||
\sa qrand()
|
||||
|
@ -56,7 +56,9 @@
|
||||
*/
|
||||
#define QT_VERSION_CHECK(major, minor, patch) ((major<<16)|(minor<<8)|(patch))
|
||||
|
||||
#ifndef QT_BOOTSTRAPPED
|
||||
#ifdef QT_BOOTSTRAPPED
|
||||
#include <QtCore/qconfig-bootstrapped.h>
|
||||
#else
|
||||
#include <QtCore/qconfig.h>
|
||||
#include <QtCore/qtcore-config.h>
|
||||
#endif
|
||||
|
@ -558,7 +558,7 @@ public:
|
||||
Key_Insert = 0x01000006,
|
||||
Key_Delete = 0x01000007,
|
||||
Key_Pause = 0x01000008,
|
||||
Key_Print = 0x01000009,
|
||||
Key_Print = 0x01000009, // print screen
|
||||
Key_SysReq = 0x0100000a,
|
||||
Key_Clear = 0x0100000b,
|
||||
Key_Home = 0x01000010, // cursor movement
|
||||
|
@ -1761,17 +1761,6 @@
|
||||
\value Key_Zoom
|
||||
\value Key_Exit
|
||||
\value Key_Cancel
|
||||
\value Key_MicVolumeUp
|
||||
\value Key_Find
|
||||
\value Key_Open
|
||||
\value Key_MicVolumeDown
|
||||
\value Key_New
|
||||
\value Key_Settings
|
||||
\value Key_Redo
|
||||
\value Key_Exit
|
||||
\value Key_Info
|
||||
\value Key_Undo
|
||||
\value Key_Guide
|
||||
|
||||
\sa QKeyEvent::key()
|
||||
*/
|
||||
@ -2300,7 +2289,7 @@
|
||||
\enum Qt::ItemSelectionMode
|
||||
|
||||
This enum is used in QGraphicsItem, QGraphicsScene and QGraphicsView to
|
||||
specify how items are selected, or how to determine if a shapes and items
|
||||
specify how items are selected, or how to determine if shapes and items
|
||||
collide.
|
||||
|
||||
\value ContainsItemShape The output list contains only items whose
|
||||
|
@ -101,13 +101,13 @@ static bool isPackage(const QFileSystemMetaData &data, const QFileSystemEntry &e
|
||||
|
||||
if (suffix.length() > 0) {
|
||||
// First step: is the extension known ?
|
||||
QCFType<CFStringRef> extensionRef = QCFString::toCFStringRef(suffix);
|
||||
QCFType<CFStringRef> extensionRef = suffix.toCFString();
|
||||
QCFType<CFStringRef> uniformTypeIdentifier = UTTypeCreatePreferredIdentifierForTag(kUTTagClassFilenameExtension, extensionRef, NULL);
|
||||
if (UTTypeConformsTo(uniformTypeIdentifier, kUTTypeBundle))
|
||||
return true;
|
||||
|
||||
// Second step: check if an application knows the package type
|
||||
QCFType<CFStringRef> path = QCFString::toCFStringRef(entry.filePath());
|
||||
QCFType<CFStringRef> path = entry.filePath().toCFString();
|
||||
QCFType<CFURLRef> url = CFURLCreateWithFileSystemPath(0, path, kCFURLPOSIXPathStyle, true);
|
||||
|
||||
UInt32 type, creator;
|
||||
@ -126,7 +126,7 @@ static bool isPackage(const QFileSystemMetaData &data, const QFileSystemEntry &e
|
||||
if (application) {
|
||||
QCFType<CFBundleRef> bundle = CFBundleCreate(kCFAllocatorDefault, application);
|
||||
CFStringRef identifier = CFBundleGetIdentifier(bundle);
|
||||
QString applicationId = QCFString::toQString(identifier);
|
||||
QString applicationId = QString::fromCFString(identifier);
|
||||
if (applicationId != QLatin1String("com.apple.finder"))
|
||||
return true;
|
||||
}
|
||||
@ -222,7 +222,7 @@ QFileSystemEntry QFileSystemEngine::getLinkTarget(const QFileSystemEntry &link,
|
||||
if (!cfstr)
|
||||
return QFileSystemEntry();
|
||||
|
||||
return QFileSystemEntry(QCFString::toQString(cfstr));
|
||||
return QFileSystemEntry(QString::fromCFString(cfstr));
|
||||
}
|
||||
#endif
|
||||
return QFileSystemEntry();
|
||||
@ -412,7 +412,7 @@ QString QFileSystemEngine::bundleName(const QFileSystemEntry &entry)
|
||||
if (QCFType<CFDictionaryRef> dict = CFBundleCopyInfoDictionaryForURL(url)) {
|
||||
if (CFTypeRef name = (CFTypeRef)CFDictionaryGetValue(dict, kCFBundleNameKey)) {
|
||||
if (CFGetTypeID(name) == CFStringGetTypeID())
|
||||
return QCFString::toQString((CFStringRef)name);
|
||||
return QString::fromCFString((CFStringRef)name);
|
||||
}
|
||||
}
|
||||
return QString();
|
||||
|
@ -87,7 +87,7 @@ bool QFseventsFileSystemWatcherEngine::checkDir(DirsByName::iterator &it)
|
||||
if (res == -1) {
|
||||
needsRestart |= derefPath(info.watchedPath);
|
||||
emit emitDirectoryChanged(info.origPath, true);
|
||||
it = watchedDirectories.erase(it);
|
||||
it = watchingState.watchedDirectories.erase(it);
|
||||
} else if (st.st_ctimespec != info.ctime || st.st_mode != info.mode) {
|
||||
info.ctime = st.st_ctimespec;
|
||||
info.mode = st.st_mode;
|
||||
@ -138,7 +138,8 @@ bool QFseventsFileSystemWatcherEngine::rescanDirs(const QString &path)
|
||||
{
|
||||
bool needsRestart = false;
|
||||
|
||||
for (DirsByName::iterator it = watchedDirectories.begin(); it != watchedDirectories.end(); ) {
|
||||
for (DirsByName::iterator it = watchingState.watchedDirectories.begin();
|
||||
it != watchingState.watchedDirectories.end(); ) {
|
||||
if (it.key().startsWith(path))
|
||||
needsRestart |= checkDir(it);
|
||||
else
|
||||
@ -177,11 +178,12 @@ bool QFseventsFileSystemWatcherEngine::rescanFiles(const QString &path)
|
||||
{
|
||||
bool needsRestart = false;
|
||||
|
||||
for (FilesByPath::iterator i = watchedFiles.begin(); i != watchedFiles.end(); ) {
|
||||
for (FilesByPath::iterator i = watchingState.watchedFiles.begin();
|
||||
i != watchingState.watchedFiles.end(); ) {
|
||||
if (i.key().startsWith(path)) {
|
||||
needsRestart |= rescanFiles(i.value());
|
||||
if (i.value().isEmpty()) {
|
||||
i = watchedFiles.erase(i);
|
||||
i = watchingState.watchedFiles.erase(i);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
@ -232,8 +234,8 @@ void QFseventsFileSystemWatcherEngine::processEvent(ConstFSEventStreamRef stream
|
||||
|
||||
if (eFlags & kFSEventStreamEventFlagRootChanged) {
|
||||
// re-check everything:
|
||||
DirsByName::iterator dirIt = watchedDirectories.find(path);
|
||||
if (dirIt != watchedDirectories.end())
|
||||
DirsByName::iterator dirIt = watchingState.watchedDirectories.find(path);
|
||||
if (dirIt != watchingState.watchedDirectories.end())
|
||||
needsRestart |= checkDir(dirIt);
|
||||
needsRestart |= rescanFiles(path);
|
||||
continue;
|
||||
@ -243,13 +245,13 @@ void QFseventsFileSystemWatcherEngine::processEvent(ConstFSEventStreamRef stream
|
||||
needsRestart |= rescanDirs(path);
|
||||
|
||||
// check watched directories:
|
||||
DirsByName::iterator dirIt = watchedDirectories.find(path);
|
||||
if (dirIt != watchedDirectories.end())
|
||||
DirsByName::iterator dirIt = watchingState.watchedDirectories.find(path);
|
||||
if (dirIt != watchingState.watchedDirectories.end())
|
||||
needsRestart |= checkDir(dirIt);
|
||||
|
||||
// check watched files:
|
||||
FilesByPath::iterator pIt = watchedFiles.find(path);
|
||||
if (pIt != watchedFiles.end())
|
||||
FilesByPath::iterator pIt = watchingState.watchedFiles.find(path);
|
||||
if (pIt != watchingState.watchedFiles.end())
|
||||
needsRestart |= rescanFiles(pIt.value());
|
||||
}
|
||||
|
||||
@ -276,12 +278,11 @@ void QFseventsFileSystemWatcherEngine::doEmitDirectoryChanged(const QString &pat
|
||||
emit directoryChanged(path, removed);
|
||||
}
|
||||
|
||||
void QFseventsFileSystemWatcherEngine::restartStream()
|
||||
bool QFseventsFileSystemWatcherEngine::restartStream()
|
||||
{
|
||||
QMacAutoReleasePool pool;
|
||||
QMutexLocker locker(&lock);
|
||||
stopStream();
|
||||
startStream();
|
||||
return startStream();
|
||||
}
|
||||
|
||||
QFseventsFileSystemWatcherEngine *QFseventsFileSystemWatcherEngine::create(QObject *parent)
|
||||
@ -311,6 +312,7 @@ QFseventsFileSystemWatcherEngine::~QFseventsFileSystemWatcherEngine()
|
||||
{
|
||||
QMacAutoReleasePool pool;
|
||||
|
||||
// Stop the stream in case we have to wait for the lock below to be acquired.
|
||||
if (stream)
|
||||
FSEventStreamStop(stream);
|
||||
|
||||
@ -334,8 +336,10 @@ QStringList QFseventsFileSystemWatcherEngine::addPaths(const QStringList &paths,
|
||||
|
||||
QMutexLocker locker(&lock);
|
||||
|
||||
bool wasRunning = stream != Q_NULLPTR;
|
||||
bool needsRestart = false;
|
||||
|
||||
WatchingState oldState = watchingState;
|
||||
QStringList p = paths;
|
||||
QMutableListIterator<QString> it(p);
|
||||
while (it.hasNext()) {
|
||||
@ -356,7 +360,7 @@ QStringList QFseventsFileSystemWatcherEngine::addPaths(const QStringList &paths,
|
||||
|
||||
const bool isDir = S_ISDIR(st.st_mode);
|
||||
if (isDir) {
|
||||
if (watchedDirectories.contains(realPath))
|
||||
if (watchingState.watchedDirectories.contains(realPath))
|
||||
continue;
|
||||
directories->append(origPath);
|
||||
watchedPath = realPath;
|
||||
@ -371,17 +375,18 @@ QStringList QFseventsFileSystemWatcherEngine::addPaths(const QStringList &paths,
|
||||
parentPath = watchedPath;
|
||||
}
|
||||
|
||||
for (PathRefCounts::const_iterator i = watchedPaths.begin(), ei = watchedPaths.end(); i != ei; ++i) {
|
||||
for (PathRefCounts::const_iterator i = watchingState.watchedPaths.begin(),
|
||||
ei = watchingState.watchedPaths.end(); i != ei; ++i) {
|
||||
if (watchedPath.startsWith(i.key())) {
|
||||
watchedPath = i.key();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
PathRefCounts::iterator it = watchedPaths.find(watchedPath);
|
||||
if (it == watchedPaths.end()) {
|
||||
PathRefCounts::iterator it = watchingState.watchedPaths.find(watchedPath);
|
||||
if (it == watchingState.watchedPaths.end()) {
|
||||
needsRestart = true;
|
||||
watchedPaths.insert(watchedPath, 1);
|
||||
watchingState.watchedPaths.insert(watchedPath, 1);
|
||||
DEBUG("Adding '%s' to watchedPaths", qPrintable(watchedPath));
|
||||
} else {
|
||||
++it.value();
|
||||
@ -392,18 +397,25 @@ QStringList QFseventsFileSystemWatcherEngine::addPaths(const QStringList &paths,
|
||||
DirInfo dirInfo;
|
||||
dirInfo.dirInfo = info;
|
||||
dirInfo.entries = scanForDirEntries(realPath);
|
||||
watchedDirectories.insert(realPath, dirInfo);
|
||||
watchingState.watchedDirectories.insert(realPath, dirInfo);
|
||||
DEBUG("-- Also adding '%s' to watchedDirectories", qPrintable(realPath));
|
||||
} else {
|
||||
watchedFiles[parentPath].insert(realPath, info);
|
||||
watchingState.watchedFiles[parentPath].insert(realPath, info);
|
||||
DEBUG("-- Also adding '%s' to watchedFiles", qPrintable(realPath));
|
||||
}
|
||||
}
|
||||
|
||||
if (needsRestart) {
|
||||
stopStream();
|
||||
if (!startStream())
|
||||
if (!startStream()) {
|
||||
// ok, something went wrong, let's try to restore the previous state
|
||||
watchingState = qMove(oldState);
|
||||
// and because we don't know which path caused the issue (if any), fail on all of them
|
||||
p = paths;
|
||||
|
||||
if (wasRunning)
|
||||
startStream();
|
||||
}
|
||||
}
|
||||
|
||||
return p;
|
||||
@ -419,6 +431,7 @@ QStringList QFseventsFileSystemWatcherEngine::removePaths(const QStringList &pat
|
||||
|
||||
bool needsRestart = false;
|
||||
|
||||
WatchingState oldState = watchingState;
|
||||
QStringList p = paths;
|
||||
QMutableListIterator<QString> it(p);
|
||||
while (it.hasNext()) {
|
||||
@ -431,10 +444,10 @@ QStringList QFseventsFileSystemWatcherEngine::removePaths(const QStringList &pat
|
||||
realPath = fi.canonicalFilePath();
|
||||
|
||||
if (fi.isDir()) {
|
||||
DirsByName::iterator dirIt = watchedDirectories.find(realPath);
|
||||
if (dirIt != watchedDirectories.end()) {
|
||||
DirsByName::iterator dirIt = watchingState.watchedDirectories.find(realPath);
|
||||
if (dirIt != watchingState.watchedDirectories.end()) {
|
||||
needsRestart |= derefPath(dirIt->dirInfo.watchedPath);
|
||||
watchedDirectories.erase(dirIt);
|
||||
watchingState.watchedDirectories.erase(dirIt);
|
||||
directories->removeAll(origPath);
|
||||
it.remove();
|
||||
DEBUG("Removed directory '%s'", qPrintable(realPath));
|
||||
@ -442,15 +455,15 @@ QStringList QFseventsFileSystemWatcherEngine::removePaths(const QStringList &pat
|
||||
} else {
|
||||
QFileInfo fi(realPath);
|
||||
QString parentPath = fi.path();
|
||||
FilesByPath::iterator pIt = watchedFiles.find(parentPath);
|
||||
if (pIt != watchedFiles.end()) {
|
||||
FilesByPath::iterator pIt = watchingState.watchedFiles.find(parentPath);
|
||||
if (pIt != watchingState.watchedFiles.end()) {
|
||||
InfoByName &filesInDir = pIt.value();
|
||||
InfoByName::iterator fIt = filesInDir.find(realPath);
|
||||
if (fIt != filesInDir.end()) {
|
||||
needsRestart |= derefPath(fIt->watchedPath);
|
||||
filesInDir.erase(fIt);
|
||||
if (filesInDir.isEmpty())
|
||||
watchedFiles.erase(pIt);
|
||||
watchingState.watchedFiles.erase(pIt);
|
||||
files->removeAll(origPath);
|
||||
it.remove();
|
||||
DEBUG("Removed file '%s'", qPrintable(realPath));
|
||||
@ -461,26 +474,33 @@ QStringList QFseventsFileSystemWatcherEngine::removePaths(const QStringList &pat
|
||||
|
||||
locker.unlock();
|
||||
|
||||
if (needsRestart)
|
||||
restartStream();
|
||||
if (needsRestart) {
|
||||
if (!restartStream()) {
|
||||
watchingState = qMove(oldState);
|
||||
startStream();
|
||||
}
|
||||
}
|
||||
|
||||
return p;
|
||||
}
|
||||
|
||||
// Returns false if FSEventStream* calls failed for some mysterious reason, true if things got a
|
||||
// thumbs-up.
|
||||
bool QFseventsFileSystemWatcherEngine::startStream()
|
||||
{
|
||||
Q_ASSERT(stream == 0);
|
||||
QMacAutoReleasePool pool;
|
||||
if (stream) // This shouldn't happen, but let's be nice and handle it.
|
||||
if (stream) // Ok, this really shouldn't happen, esp. not after the assert. But let's be nice in release mode and still handle it.
|
||||
stopStream();
|
||||
|
||||
if (watchedPaths.isEmpty())
|
||||
return false;
|
||||
QMacAutoReleasePool pool;
|
||||
|
||||
DEBUG() << "Starting stream with paths" << watchedPaths.keys();
|
||||
if (watchingState.watchedPaths.isEmpty())
|
||||
return true; // we succeeded in doing nothing
|
||||
|
||||
NSMutableArray *pathsToWatch = [NSMutableArray arrayWithCapacity:watchedPaths.size()];
|
||||
for (PathRefCounts::const_iterator i = watchedPaths.begin(), ei = watchedPaths.end(); i != ei; ++i)
|
||||
DEBUG() << "Starting stream with paths" << watchingState.watchedPaths.keys();
|
||||
|
||||
NSMutableArray *pathsToWatch = [NSMutableArray arrayWithCapacity:watchingState.watchedPaths.size()];
|
||||
for (PathRefCounts::const_iterator i = watchingState.watchedPaths.begin(), ei = watchingState.watchedPaths.end(); i != ei; ++i)
|
||||
[pathsToWatch addObject:i.key().toNSString()];
|
||||
|
||||
struct FSEventStreamContext callBackInfo = {
|
||||
@ -504,7 +524,7 @@ bool QFseventsFileSystemWatcherEngine::startStream()
|
||||
latency,
|
||||
FSEventStreamCreateFlags(0));
|
||||
|
||||
if (!stream) {
|
||||
if (!stream) { // nope, no way to know what went wrong, so just fail
|
||||
DEBUG() << "Failed to create stream!";
|
||||
return false;
|
||||
}
|
||||
@ -514,7 +534,7 @@ bool QFseventsFileSystemWatcherEngine::startStream()
|
||||
if (FSEventStreamStart(stream)) {
|
||||
DEBUG() << "Stream started successfully with sinceWhen =" << lastReceivedEvent;
|
||||
return true;
|
||||
} else {
|
||||
} else { // again, no way to know what went wrong, so just clean up and fail
|
||||
DEBUG() << "Stream failed to start!";
|
||||
FSEventStreamInvalidate(stream);
|
||||
FSEventStreamRelease(stream);
|
||||
@ -525,6 +545,7 @@ bool QFseventsFileSystemWatcherEngine::startStream()
|
||||
|
||||
void QFseventsFileSystemWatcherEngine::stopStream(bool isStopped)
|
||||
{
|
||||
QMacAutoReleasePool pool;
|
||||
if (stream) {
|
||||
if (!isStopped)
|
||||
FSEventStreamStop(stream);
|
||||
@ -554,9 +575,9 @@ QFseventsFileSystemWatcherEngine::InfoByName QFseventsFileSystemWatcherEngine::s
|
||||
|
||||
bool QFseventsFileSystemWatcherEngine::derefPath(const QString &watchedPath)
|
||||
{
|
||||
PathRefCounts::iterator it = watchedPaths.find(watchedPath);
|
||||
if (it != watchedPaths.end() && --it.value() < 1) {
|
||||
watchedPaths.erase(it);
|
||||
PathRefCounts::iterator it = watchingState.watchedPaths.find(watchedPath);
|
||||
if (it != watchingState.watchedPaths.end() && --it.value() < 1) {
|
||||
watchingState.watchedPaths.erase(it);
|
||||
DEBUG("Removing '%s' from watchedPaths.", qPrintable(watchedPath));
|
||||
return true;
|
||||
}
|
||||
|
@ -87,7 +87,7 @@ Q_SIGNALS:
|
||||
private slots:
|
||||
void doEmitFileChanged(const QString &path, bool removed);
|
||||
void doEmitDirectoryChanged(const QString &path, bool removed);
|
||||
void restartStream();
|
||||
bool restartStream();
|
||||
|
||||
private:
|
||||
struct Info {
|
||||
@ -118,6 +118,19 @@ private:
|
||||
typedef QHash<QString, DirInfo> DirsByName;
|
||||
typedef QHash<QString, qint64> PathRefCounts;
|
||||
|
||||
struct WatchingState {
|
||||
// These fields go hand-in-hand. FSEvents watches paths, and there is no use in watching
|
||||
// the same path multiple times. So, the "refcount" on a path is the number of watched
|
||||
// files that have the same path, plus the number of directories that have the same path.
|
||||
//
|
||||
// If the stream fails to start after adding files/directories, the watcher will try to
|
||||
// keep watching files/directories that it was already watching. It does that by restoring
|
||||
// the previous WatchingState and restarting the stream.
|
||||
FilesByPath watchedFiles;
|
||||
DirsByName watchedDirectories;
|
||||
PathRefCounts watchedPaths;
|
||||
};
|
||||
|
||||
QFseventsFileSystemWatcherEngine(QObject *parent);
|
||||
bool startStream();
|
||||
void stopStream(bool isStopped = false);
|
||||
@ -131,10 +144,8 @@ private:
|
||||
QMutex lock;
|
||||
dispatch_queue_t queue;
|
||||
FSEventStreamRef stream;
|
||||
FilesByPath watchedFiles;
|
||||
DirsByName watchedDirectories;
|
||||
PathRefCounts watchedPaths;
|
||||
FSEventStreamEventId lastReceivedEvent;
|
||||
WatchingState watchingState;
|
||||
};
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
@ -120,6 +120,14 @@ static void checkWarnMessage(const QIODevice *device, const char *function, cons
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define CHECK_MAXBYTEARRAYSIZE(function) \
|
||||
do { \
|
||||
if (maxSize >= MaxByteArraySize) { \
|
||||
checkWarnMessage(this, #function, "maxSize argument exceeds QByteArray size limit"); \
|
||||
maxSize = MaxByteArraySize - 1; \
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#define CHECK_WRITABLE(function, returnType) \
|
||||
do { \
|
||||
if ((d->openMode & WriteOnly) == 0) { \
|
||||
@ -1178,10 +1186,7 @@ QByteArray QIODevice::read(qint64 maxSize)
|
||||
}
|
||||
|
||||
CHECK_MAXLEN(read, result);
|
||||
if (maxSize >= MaxByteArraySize) {
|
||||
checkWarnMessage(this, "read", "maxSize argument exceeds QByteArray size limit");
|
||||
maxSize = MaxByteArraySize - 1;
|
||||
}
|
||||
CHECK_MAXBYTEARRAYSIZE(read);
|
||||
|
||||
result.resize(int(maxSize));
|
||||
qint64 readBytes = read(result.data(), result.size());
|
||||
@ -1402,17 +1407,13 @@ QByteArray QIODevice::readLine(qint64 maxSize)
|
||||
QByteArray result;
|
||||
|
||||
CHECK_MAXLEN(readLine, result);
|
||||
CHECK_MAXBYTEARRAYSIZE(readLine);
|
||||
|
||||
#if defined QIODEVICE_DEBUG
|
||||
printf("%p QIODevice::readLine(%lld), d->pos = %lld, d->buffer.size() = %lld\n",
|
||||
this, maxSize, d->pos, d->buffer.size());
|
||||
#endif
|
||||
|
||||
if (maxSize >= MaxByteArraySize) {
|
||||
qWarning("QIODevice::read: maxSize argument exceeds QByteArray size limit");
|
||||
maxSize = MaxByteArraySize - 1;
|
||||
}
|
||||
|
||||
result.resize(int(maxSize));
|
||||
qint64 readBytes = 0;
|
||||
if (!result.size()) {
|
||||
|
@ -418,7 +418,7 @@ void QProcessPrivate::startProcess()
|
||||
}
|
||||
if (url) {
|
||||
const QCFString str = CFURLCopyFileSystemPath(url, kCFURLPOSIXPathStyle);
|
||||
encodedProgramName += (QDir::separator() + QDir(program).relativeFilePath(QCFString::toQString(str))).toUtf8();
|
||||
encodedProgramName += (QDir::separator() + QDir(program).relativeFilePath(QString::fromCFString(str))).toUtf8();
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
@ -427,7 +427,9 @@ QString QSettingsPrivate::variantToString(const QVariant &v)
|
||||
case QVariant::Double:
|
||||
case QVariant::KeySequence: {
|
||||
result = v.toString();
|
||||
if (result.startsWith(QLatin1Char('@')))
|
||||
if (result.contains(QChar::Null))
|
||||
result = QLatin1String("@String(") + result + QLatin1Char(')');
|
||||
else if (result.startsWith(QLatin1Char('@')))
|
||||
result.prepend(QLatin1Char('@'));
|
||||
break;
|
||||
}
|
||||
@ -487,6 +489,8 @@ QVariant QSettingsPrivate::stringToVariant(const QString &s)
|
||||
if (s.endsWith(QLatin1Char(')'))) {
|
||||
if (s.startsWith(QLatin1String("@ByteArray("))) {
|
||||
return QVariant(s.midRef(11, s.size() - 12).toLatin1());
|
||||
} else if (s.startsWith(QLatin1String("@String("))) {
|
||||
return QVariant(s.midRef(8, s.size() - 9).toString());
|
||||
} else if (s.startsWith(QLatin1String("@Variant("))
|
||||
|| s.startsWith(QLatin1String("@DateTime("))) {
|
||||
#ifndef QT_NO_DATASTREAM
|
||||
|
@ -80,6 +80,9 @@ public:
|
||||
AccessError,
|
||||
FormatError
|
||||
};
|
||||
#ifndef QT_NO_QOBJECT
|
||||
Q_ENUM(Status)
|
||||
#endif
|
||||
|
||||
enum Format {
|
||||
NativeFormat,
|
||||
@ -108,11 +111,17 @@ public:
|
||||
CustomFormat15,
|
||||
CustomFormat16
|
||||
};
|
||||
#ifndef QT_NO_QOBJECT
|
||||
Q_ENUM(Format)
|
||||
#endif
|
||||
|
||||
enum Scope {
|
||||
UserScope,
|
||||
SystemScope
|
||||
};
|
||||
#ifndef QT_NO_QOBJECT
|
||||
Q_ENUM(Scope)
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_QOBJECT
|
||||
explicit QSettings(const QString &organization,
|
||||
|
@ -83,12 +83,12 @@ static QString rotateSlashesDotsAndMiddots(const QString &key, int shift)
|
||||
|
||||
static QCFType<CFStringRef> macKey(const QString &key)
|
||||
{
|
||||
return QCFString::toCFStringRef(rotateSlashesDotsAndMiddots(key, Macify));
|
||||
return rotateSlashesDotsAndMiddots(key, Macify).toCFString();
|
||||
}
|
||||
|
||||
static QString qtKey(CFStringRef cfkey)
|
||||
{
|
||||
return rotateSlashesDotsAndMiddots(QCFString::toQString(cfkey), Qtify);
|
||||
return rotateSlashesDotsAndMiddots(QString::fromCFString(cfkey), Qtify);
|
||||
}
|
||||
|
||||
static QCFType<CFPropertyListRef> macValue(const QVariant &value);
|
||||
@ -160,7 +160,7 @@ static QCFType<CFPropertyListRef> macValue(const QVariant &value)
|
||||
}
|
||||
}
|
||||
|
||||
cfkeys[numUniqueKeys] = QCFString::toCFStringRef(key);
|
||||
cfkeys[numUniqueKeys] = key.toCFString();
|
||||
cfvalues[numUniqueKeys] = singleton ? macValue(values.constFirst()) : macList(values);
|
||||
++numUniqueKeys;
|
||||
}
|
||||
@ -175,17 +175,12 @@ static QCFType<CFPropertyListRef> macValue(const QVariant &value)
|
||||
break;
|
||||
case QVariant::DateTime:
|
||||
{
|
||||
/*
|
||||
CFDate, unlike QDateTime, doesn't store timezone information.
|
||||
*/
|
||||
QDateTime dt = value.toDateTime();
|
||||
if (dt.timeSpec() == Qt::LocalTime) {
|
||||
QDateTime reference;
|
||||
reference.setSecsSinceEpoch(qint64(kCFAbsoluteTimeIntervalSince1970));
|
||||
result = CFDateCreate(kCFAllocatorDefault, CFAbsoluteTime(reference.secsTo(dt)));
|
||||
} else {
|
||||
QDateTime dateTime = value.toDateTime();
|
||||
// CFDate, unlike QDateTime, doesn't store timezone information
|
||||
if (dateTime.timeSpec() == Qt::LocalTime)
|
||||
result = dateTime.toCFDate();
|
||||
else
|
||||
goto string_case;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case QVariant::Bool:
|
||||
@ -214,7 +209,11 @@ static QCFType<CFPropertyListRef> macValue(const QVariant &value)
|
||||
case QVariant::String:
|
||||
string_case:
|
||||
default:
|
||||
result = QCFString::toCFStringRef(QSettingsPrivate::variantToString(value));
|
||||
QString string = QSettingsPrivate::variantToString(value);
|
||||
if (string.contains(QChar::Null))
|
||||
result = string.toUtf8().toCFData();
|
||||
else
|
||||
result = string.toCFString();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@ -230,7 +229,7 @@ static QVariant qtValue(CFPropertyListRef cfvalue)
|
||||
Sorted grossly from most to least frequent type.
|
||||
*/
|
||||
if (typeId == CFStringGetTypeID()) {
|
||||
return QSettingsPrivate::stringToVariant(QCFString::toQString(static_cast<CFStringRef>(cfvalue)));
|
||||
return QSettingsPrivate::stringToVariant(QString::fromCFString(static_cast<CFStringRef>(cfvalue)));
|
||||
} else if (typeId == CFNumberGetTypeID()) {
|
||||
CFNumberRef cfnumber = static_cast<CFNumberRef>(cfvalue);
|
||||
if (CFNumberIsFloatType(cfnumber)) {
|
||||
@ -266,9 +265,16 @@ static QVariant qtValue(CFPropertyListRef cfvalue)
|
||||
} else if (typeId == CFBooleanGetTypeID()) {
|
||||
return (bool)CFBooleanGetValue(static_cast<CFBooleanRef>(cfvalue));
|
||||
} else if (typeId == CFDataGetTypeID()) {
|
||||
CFDataRef cfdata = static_cast<CFDataRef>(cfvalue);
|
||||
return QByteArray(reinterpret_cast<const char *>(CFDataGetBytePtr(cfdata)),
|
||||
CFDataGetLength(cfdata));
|
||||
QByteArray byteArray = QByteArray::fromRawCFData(static_cast<CFDataRef>(cfvalue));
|
||||
|
||||
// Fast-path for QByteArray, so that we don't have to go
|
||||
// though the expensive and lossy conversion via UTF-8.
|
||||
if (!byteArray.startsWith('@'))
|
||||
return byteArray;
|
||||
|
||||
const QString str = QString::fromUtf8(byteArray.constData(), byteArray.size());
|
||||
return QSettingsPrivate::stringToVariant(str);
|
||||
|
||||
} else if (typeId == CFDictionaryGetTypeID()) {
|
||||
CFDictionaryRef cfdict = static_cast<CFDictionaryRef>(cfvalue);
|
||||
CFTypeID arrayTypeId = CFArrayGetTypeID();
|
||||
@ -279,7 +285,7 @@ static QVariant qtValue(CFPropertyListRef cfvalue)
|
||||
|
||||
QMultiMap<QString, QVariant> map;
|
||||
for (int i = 0; i < size; ++i) {
|
||||
QString key = QCFString::toQString(static_cast<CFStringRef>(keys[i]));
|
||||
QString key = QString::fromCFString(static_cast<CFStringRef>(keys[i]));
|
||||
|
||||
if (CFGetTypeID(values[i]) == arrayTypeId) {
|
||||
CFArrayRef cfarray = static_cast<CFArrayRef>(values[i]);
|
||||
@ -292,9 +298,7 @@ static QVariant qtValue(CFPropertyListRef cfvalue)
|
||||
}
|
||||
return map;
|
||||
} else if (typeId == CFDateGetTypeID()) {
|
||||
QDateTime dt;
|
||||
dt.setSecsSinceEpoch(qint64(kCFAbsoluteTimeIntervalSince1970));
|
||||
return dt.addSecs((int)CFDateGetAbsoluteTime(static_cast<CFDateRef>(cfvalue)));
|
||||
return QDateTime::fromCFDate(static_cast<CFDateRef>(cfvalue));
|
||||
}
|
||||
return QVariant();
|
||||
}
|
||||
@ -571,7 +575,7 @@ QString QMacSettingsPrivate::fileName() const
|
||||
if (scope == QSettings::UserScope)
|
||||
result = QDir::homePath();
|
||||
result += QLatin1String("/Library/Preferences/");
|
||||
result += QCFString::toQString(domains[0].applicationOrSuiteId);
|
||||
result += QString::fromCFString(domains[0].applicationOrSuiteId);
|
||||
result += QLatin1String(".plist");
|
||||
return result;
|
||||
}
|
||||
|
@ -667,15 +667,6 @@ void QWinSettingsPrivate::remove(const QString &uKey)
|
||||
}
|
||||
}
|
||||
|
||||
static bool stringContainsNullChar(const QString &s)
|
||||
{
|
||||
for (int i = 0; i < s.length(); ++i) {
|
||||
if (s.at(i).unicode() == 0)
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
void QWinSettingsPrivate::set(const QString &uKey, const QVariant &value)
|
||||
{
|
||||
if (writeHandle() == 0) {
|
||||
@ -704,7 +695,7 @@ void QWinSettingsPrivate::set(const QString &uKey, const QVariant &value)
|
||||
QStringList l = variantListToStringList(value.toList());
|
||||
QStringList::const_iterator it = l.constBegin();
|
||||
for (; it != l.constEnd(); ++it) {
|
||||
if ((*it).length() == 0 || stringContainsNullChar(*it)) {
|
||||
if ((*it).length() == 0 || it->contains(QChar::Null)) {
|
||||
type = REG_BINARY;
|
||||
break;
|
||||
}
|
||||
@ -748,7 +739,7 @@ void QWinSettingsPrivate::set(const QString &uKey, const QVariant &value)
|
||||
// If the string does not contain '\0', we can use REG_SZ, the native registry
|
||||
// string type. Otherwise we use REG_BINARY.
|
||||
QString s = variantToString(value);
|
||||
type = stringContainsNullChar(s) ? REG_BINARY : REG_SZ;
|
||||
type = s.contains(QChar::Null) ? REG_BINARY : REG_SZ;
|
||||
if (type == REG_BINARY) {
|
||||
regValueBuff = QByteArray((const char*)s.utf16(), s.length() * 2);
|
||||
} else {
|
||||
|
@ -402,7 +402,7 @@ void QWinRTSettingsPrivate::set(const QString &uKey, const QVariant &value)
|
||||
QStringList::const_iterator it = l.constBegin();
|
||||
bool containsNull = false;
|
||||
for (; it != l.constEnd(); ++it) {
|
||||
if ((*it).length() == 0 || it->indexOf(QChar::Null) != -1) {
|
||||
if ((*it).length() == 0 || it->contains(QChar::Null)) {
|
||||
// We can only store as binary
|
||||
containsNull = true;
|
||||
break;
|
||||
@ -445,7 +445,7 @@ void QWinRTSettingsPrivate::set(const QString &uKey, const QVariant &value)
|
||||
break;
|
||||
default: {
|
||||
const QString s = variantToString(value);
|
||||
if (s.indexOf(QChar::Null) != -1) {
|
||||
if (s.contains(QChar::Null)) {
|
||||
hr = valueStatics->CreateUInt8Array(s.length() * 2, (BYTE*) s.utf16(), &val);
|
||||
} else {
|
||||
HStringReference ref((const wchar_t*)s.utf16(), s.size());
|
||||
|
@ -168,36 +168,11 @@ static QString baseWritableLocation(QStandardPaths::StandardLocation type,
|
||||
|
||||
QString QStandardPaths::writableLocation(StandardLocation type)
|
||||
{
|
||||
if (isTestModeEnabled()) {
|
||||
const QString qttestDir = QDir::homePath() + QLatin1String("/.qttest");
|
||||
QString path;
|
||||
switch (type) {
|
||||
case GenericDataLocation:
|
||||
case AppDataLocation:
|
||||
case AppLocalDataLocation:
|
||||
path = qttestDir + QLatin1String("/Application Support");
|
||||
if (type != GenericDataLocation)
|
||||
appendOrganizationAndApp(path);
|
||||
return path;
|
||||
case GenericCacheLocation:
|
||||
case CacheLocation:
|
||||
path = qttestDir + QLatin1String("/Cache");
|
||||
if (type == CacheLocation)
|
||||
appendOrganizationAndApp(path);
|
||||
return path;
|
||||
case GenericConfigLocation:
|
||||
case ConfigLocation:
|
||||
case AppConfigLocation:
|
||||
path = qttestDir + QLatin1String("/Preferences");
|
||||
if (type == AppConfigLocation)
|
||||
appendOrganizationAndApp(path);
|
||||
return path;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
QString location = baseWritableLocation(type, NSUserDomainMask, true);
|
||||
if (isTestModeEnabled())
|
||||
location = location.replace(QDir::homePath(), QDir::homePath() + QLatin1String("/.qttest"));
|
||||
|
||||
return baseWritableLocation(type, NSUserDomainMask, true);
|
||||
return location;
|
||||
}
|
||||
|
||||
QStringList QStandardPaths::standardLocations(StandardLocation type)
|
||||
@ -230,13 +205,13 @@ QStringList QStandardPaths::standardLocations(StandardLocation type)
|
||||
if (mainBundle) {
|
||||
CFURLRef bundleUrl = CFBundleCopyBundleURL(mainBundle);
|
||||
CFStringRef cfBundlePath = CFURLCopyPath(bundleUrl);
|
||||
QString bundlePath = QCFString::toQString(cfBundlePath);
|
||||
QString bundlePath = QString::fromCFString(cfBundlePath);
|
||||
CFRelease(cfBundlePath);
|
||||
CFRelease(bundleUrl);
|
||||
|
||||
CFURLRef resourcesUrl = CFBundleCopyResourcesDirectoryURL(mainBundle);
|
||||
CFStringRef cfResourcesPath = CFURLCopyPath(resourcesUrl);
|
||||
QString resourcesPath = QCFString::toQString(cfResourcesPath);
|
||||
QString resourcesPath = QString::fromCFString(cfResourcesPath);
|
||||
CFRelease(cfResourcesPath);
|
||||
CFRelease(resourcesUrl);
|
||||
|
||||
|
@ -665,7 +665,7 @@ QString QTemporaryFile::fileTemplate() const
|
||||
|
||||
/*!
|
||||
Sets the static portion of the file name to \a name. If the file
|
||||
template ends in XXXXXX that will automatically be replaced with
|
||||
template contains XXXXXX that will automatically be replaced with
|
||||
the unique part of the filename, otherwise a filename will be
|
||||
determined automatically based on the static portion specified.
|
||||
|
||||
|
@ -37,6 +37,10 @@
|
||||
**
|
||||
****************************************************************************/
|
||||
|
||||
#include <qglobal.h>
|
||||
|
||||
#if QT_CONFIG(topleveldomain)
|
||||
|
||||
#include "qplatformdefs.h"
|
||||
#include "qurl.h"
|
||||
#include "private/qurltlds_p.h"
|
||||
@ -125,3 +129,5 @@ Q_CORE_EXPORT bool qIsEffectiveTLD(const QStringRef &domain)
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
@ -55,6 +55,8 @@
|
||||
#include "QtCore/qurl.h"
|
||||
#include "QtCore/qstring.h"
|
||||
|
||||
QT_REQUIRE_CONFIG(topleveldomain);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
Q_CORE_EXPORT QString qTopLevelDomain(const QString &domain);
|
||||
|
@ -3117,6 +3117,7 @@ bool QUrl::hasFragment() const
|
||||
return d->hasFragment();
|
||||
}
|
||||
|
||||
#if QT_CONFIG(topleveldomain)
|
||||
/*!
|
||||
\since 4.8
|
||||
|
||||
@ -3151,6 +3152,7 @@ QString QUrl::topLevelDomain(ComponentFormattingOptions options) const
|
||||
}
|
||||
return tld;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*!
|
||||
Returns the result of the merge of this URL with \a relative. This
|
||||
|
@ -235,7 +235,9 @@ public:
|
||||
|
||||
void setHost(const QString &host, ParsingMode mode = DecodedMode);
|
||||
QString host(ComponentFormattingOptions = FullyDecoded) const;
|
||||
#if QT_CONFIG(topleveldomain)
|
||||
QString topLevelDomain(ComponentFormattingOptions options = FullyDecoded) const;
|
||||
#endif
|
||||
|
||||
void setPort(int port);
|
||||
int port(int defaultPort = -1) const;
|
||||
|
@ -375,8 +375,8 @@ QDateTime QDateTime::fromCFDate(CFDateRef date)
|
||||
{
|
||||
if (!date)
|
||||
return QDateTime();
|
||||
return QDateTime::fromMSecsSinceEpoch(static_cast<qint64>((CFDateGetAbsoluteTime(date)
|
||||
+ kCFAbsoluteTimeIntervalSince1970) * 1000));
|
||||
CFAbsoluteTime sSinceEpoch = kCFAbsoluteTimeIntervalSince1970 + CFDateGetAbsoluteTime(date);
|
||||
return QDateTime::fromMSecsSinceEpoch(qRound64(sSinceEpoch * 1000));
|
||||
}
|
||||
|
||||
/*!
|
||||
@ -404,7 +404,7 @@ QDateTime QDateTime::fromNSDate(const NSDate *date)
|
||||
{
|
||||
if (!date)
|
||||
return QDateTime();
|
||||
return QDateTime::fromMSecsSinceEpoch(static_cast<qint64>([date timeIntervalSince1970] * 1000));
|
||||
return QDateTime::fromMSecsSinceEpoch(qRound64([date timeIntervalSince1970] * 1000));
|
||||
}
|
||||
|
||||
/*!
|
||||
|
@ -43,37 +43,17 @@
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
QString QCFString::toQString(CFStringRef str)
|
||||
{
|
||||
if(!str)
|
||||
return QString();
|
||||
CFIndex length = CFStringGetLength(str);
|
||||
const UniChar *chars = CFStringGetCharactersPtr(str);
|
||||
if (chars)
|
||||
return QString(reinterpret_cast<const QChar *>(chars), length);
|
||||
|
||||
QVarLengthArray<UniChar> buffer(length);
|
||||
CFStringGetCharacters(str, CFRangeMake(0, length), buffer.data());
|
||||
return QString(reinterpret_cast<const QChar *>(buffer.constData()), length);
|
||||
}
|
||||
|
||||
QCFString::operator QString() const
|
||||
{
|
||||
if (string.isEmpty() && type)
|
||||
const_cast<QCFString*>(this)->string = toQString(type);
|
||||
const_cast<QCFString*>(this)->string = QString::fromCFString(type);
|
||||
return string;
|
||||
}
|
||||
|
||||
CFStringRef QCFString::toCFStringRef(const QString &string)
|
||||
{
|
||||
return CFStringCreateWithCharacters(0, reinterpret_cast<const UniChar *>(string.unicode()),
|
||||
string.length());
|
||||
}
|
||||
|
||||
QCFString::operator CFStringRef() const
|
||||
{
|
||||
if (!type)
|
||||
const_cast<QCFString*>(this)->type = toCFStringRef(string);
|
||||
const_cast<QCFString*>(this)->type = string.toCFString();
|
||||
return type;
|
||||
}
|
||||
|
||||
|
@ -49,17 +49,6 @@
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
NSString *QCFString::toNSString(const QString &string)
|
||||
{
|
||||
// The const cast below is safe: CfStringRef is immutable and so is NSString.
|
||||
return [const_cast<NSString *>(reinterpret_cast<const NSString *>(toCFStringRef(string))) autorelease];
|
||||
}
|
||||
|
||||
QString QCFString::toQString(const NSString *nsstr)
|
||||
{
|
||||
return toQString(reinterpret_cast<CFStringRef>(nsstr));
|
||||
}
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
|
||||
QDebug operator<<(QDebug dbg, const NSObject *nsObject)
|
||||
|
@ -126,12 +126,6 @@ public:
|
||||
inline QCFString(const QCFType<CFStringRef> &other) : QCFType<CFStringRef>(other) {}
|
||||
operator QString() const;
|
||||
operator CFStringRef() const;
|
||||
static QString toQString(CFStringRef cfstr);
|
||||
static CFStringRef toCFStringRef(const QString &str);
|
||||
#ifdef __OBJC__
|
||||
static QString toQString(const NSString *nsstr);
|
||||
static NSString *toNSString(const QString &string);
|
||||
#endif
|
||||
|
||||
private:
|
||||
QString string;
|
||||
|
@ -150,7 +150,7 @@ QString QCoreApplicationPrivate::macMenuBarName()
|
||||
QString bundleName;
|
||||
CFTypeRef string = CFBundleGetValueForInfoDictionaryKey(CFBundleGetMainBundle(), CFSTR("CFBundleName"));
|
||||
if (string)
|
||||
bundleName = QCFString::toQString(static_cast<CFStringRef>(string));
|
||||
bundleName = QString::fromCFString(static_cast<CFStringRef>(string));
|
||||
return bundleName;
|
||||
}
|
||||
#endif
|
||||
@ -1260,18 +1260,30 @@ int QCoreApplication::exec()
|
||||
self->d_func()->aboutToQuitEmitted = false;
|
||||
int returnCode = eventLoop.exec();
|
||||
threadData->quitNow = false;
|
||||
if (self) {
|
||||
self->d_func()->in_exec = false;
|
||||
if (!self->d_func()->aboutToQuitEmitted)
|
||||
emit self->aboutToQuit(QPrivateSignal());
|
||||
self->d_func()->aboutToQuitEmitted = true;
|
||||
sendPostedEvents(0, QEvent::DeferredDelete);
|
||||
}
|
||||
|
||||
if (self)
|
||||
self->d_func()->execCleanup();
|
||||
|
||||
return returnCode;
|
||||
}
|
||||
|
||||
|
||||
// Cleanup after eventLoop is done executing in QCoreApplication::exec().
|
||||
// This is for use cases in which QCoreApplication is instantiated by a
|
||||
// library and not by an application executable, for example, Active X
|
||||
// servers.
|
||||
|
||||
void QCoreApplicationPrivate::execCleanup()
|
||||
{
|
||||
threadData->quitNow = false;
|
||||
in_exec = false;
|
||||
if (!aboutToQuitEmitted)
|
||||
emit q_func()->aboutToQuit(QCoreApplication::QPrivateSignal());
|
||||
aboutToQuitEmitted = true;
|
||||
QCoreApplication::sendPostedEvents(0, QEvent::DeferredDelete);
|
||||
}
|
||||
|
||||
|
||||
/*!
|
||||
Tells the application to exit with a return code.
|
||||
|
||||
|
@ -145,6 +145,8 @@ public:
|
||||
static inline void clearApplicationFilePath() { delete cachedApplicationFilePath; cachedApplicationFilePath = 0; }
|
||||
|
||||
#ifndef QT_NO_QOBJECT
|
||||
void execCleanup();
|
||||
|
||||
bool in_exec;
|
||||
bool aboutToQuitEmitted;
|
||||
bool threadData_clean;
|
||||
|
@ -45,15 +45,19 @@ QT_BEGIN_NAMESPACE
|
||||
Q_GLOBAL_STATIC(QCoreGlobalData, globalInstance)
|
||||
|
||||
QCoreGlobalData::QCoreGlobalData()
|
||||
#if QT_CONFIG(textcodec)
|
||||
: codecForLocale(0)
|
||||
#endif
|
||||
{
|
||||
}
|
||||
|
||||
QCoreGlobalData::~QCoreGlobalData()
|
||||
{
|
||||
#if QT_CONFIG(textcodec)
|
||||
codecForLocale = 0;
|
||||
for (QList<QTextCodec *>::const_iterator it = allCodecs.constBegin(); it != allCodecs.constEnd(); ++it)
|
||||
delete *it;
|
||||
#endif
|
||||
}
|
||||
|
||||
QCoreGlobalData *QCoreGlobalData::instance()
|
||||
|
@ -71,9 +71,11 @@ struct QCoreGlobalData {
|
||||
QMap<QString, QStringList> dirSearchPaths;
|
||||
QReadWriteLock dirSearchPathsLock;
|
||||
|
||||
#if QT_CONFIG(textcodec)
|
||||
QList<QTextCodec*> allCodecs;
|
||||
QAtomicPointer<QTextCodec> codecForLocale;
|
||||
QTextCodecCache codecCache;
|
||||
#endif
|
||||
|
||||
static QCoreGlobalData *instance();
|
||||
};
|
||||
|
@ -117,7 +117,7 @@ static CFStringRef runLoopMode(NSDictionary *dictionary)
|
||||
if (CFStringCompare(mode, [self currentMode], 0) == kCFCompareEqualTo)
|
||||
m_runLoopModes.pop();
|
||||
else
|
||||
qWarning("Tried to pop run loop mode '%s' that was never pushed!", qPrintable(QCFString::toQString(mode)));
|
||||
qWarning("Tried to pop run loop mode '%s' that was never pushed!", qPrintable(QString::fromCFString(mode)));
|
||||
|
||||
Q_ASSERT(m_runLoopModes.size() >= 1);
|
||||
}
|
||||
@ -285,7 +285,7 @@ bool QEventDispatcherCoreFoundation::processEvents(QEventLoop::ProcessEventsFlag
|
||||
CFTimeInterval duration = (m_processEvents.flags & QEventLoop::WaitForMoreEvents) ?
|
||||
kCFTimeIntervalDistantFuture : kCFTimeIntervalMinimum;
|
||||
|
||||
qEventDispatcherDebug() << "Calling CFRunLoopRunInMode = " << qPrintable(QCFString::toQString(mode))
|
||||
qEventDispatcherDebug() << "Calling CFRunLoopRunInMode = " << qPrintable(QString::fromCFString(mode))
|
||||
<< " for " << duration << " ms, processing single source = " << returnAfterSingleSourceHandled; qIndent();
|
||||
|
||||
SInt32 result = CFRunLoopRunInMode(mode, duration, returnAfterSingleSourceHandled);
|
||||
|
@ -180,7 +180,7 @@ static inline HRESULT _await_impl(const Microsoft::WRL::ComPtr<T> &asyncOp, Awai
|
||||
t.start();
|
||||
switch (awaitStyle) {
|
||||
case ProcessMainThreadEvents:
|
||||
while (SUCCEEDED(hr = asyncInfo->get_Status(&status)) && status == Started) {
|
||||
while (SUCCEEDED(hr = asyncInfo->get_Status(&status)) && status == AsyncStatus::Started) {
|
||||
QCoreApplication::processEvents();
|
||||
if (timeout && t.hasExpired(timeout))
|
||||
return ERROR_TIMEOUT;
|
||||
@ -188,7 +188,7 @@ static inline HRESULT _await_impl(const Microsoft::WRL::ComPtr<T> &asyncOp, Awai
|
||||
break;
|
||||
case ProcessThreadEvents:
|
||||
if (QAbstractEventDispatcher *dispatcher = QThread::currentThread()->eventDispatcher()) {
|
||||
while (SUCCEEDED(hr = asyncInfo->get_Status(&status)) && status == Started) {
|
||||
while (SUCCEEDED(hr = asyncInfo->get_Status(&status)) && status == AsyncStatus::Started) {
|
||||
dispatcher->processEvents(QEventLoop::AllEvents);
|
||||
if (timeout && t.hasExpired(timeout))
|
||||
return ERROR_TIMEOUT;
|
||||
@ -198,7 +198,7 @@ static inline HRESULT _await_impl(const Microsoft::WRL::ComPtr<T> &asyncOp, Awai
|
||||
// fall through
|
||||
default:
|
||||
case YieldThread:
|
||||
while (SUCCEEDED(hr = asyncInfo->get_Status(&status)) && status == Started) {
|
||||
while (SUCCEEDED(hr = asyncInfo->get_Status(&status)) && status == AsyncStatus::Started) {
|
||||
QThread::yieldCurrentThread();
|
||||
if (timeout && t.hasExpired(timeout))
|
||||
return ERROR_TIMEOUT;
|
||||
@ -206,7 +206,7 @@ static inline HRESULT _await_impl(const Microsoft::WRL::ComPtr<T> &asyncOp, Awai
|
||||
break;
|
||||
}
|
||||
|
||||
if (FAILED(hr) || status != Completed) {
|
||||
if (FAILED(hr) || status != AsyncStatus::Completed) {
|
||||
HRESULT ec;
|
||||
hr = asyncInfo->get_ErrorCode(&ec);
|
||||
if (FAILED(hr))
|
||||
|
@ -611,6 +611,8 @@ void QTimer::singleShot(int msec, Qt::TimerType timerType, const QObject *receiv
|
||||
A single-shot timer fires only once, non-single-shot timers fire
|
||||
every \l interval milliseconds.
|
||||
|
||||
The default value for this property is \c false.
|
||||
|
||||
\sa interval, singleShot()
|
||||
*/
|
||||
|
||||
|
@ -38,9 +38,6 @@
|
||||
****************************************************************************/
|
||||
|
||||
#include "qabstractstate.h"
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
#include "qabstractstate_p.h"
|
||||
#include "qstate.h"
|
||||
#include "qstate_p.h"
|
||||
@ -237,5 +234,3 @@ bool QAbstractState::event(QEvent *e)
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
@ -42,11 +42,10 @@
|
||||
|
||||
#include <QtCore/qobject.h>
|
||||
|
||||
QT_REQUIRE_CONFIG(statemachine);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
class QState;
|
||||
class QStateMachine;
|
||||
|
||||
@ -84,8 +83,6 @@ private:
|
||||
Q_DECLARE_PRIVATE(QAbstractState)
|
||||
};
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
@ -51,13 +51,11 @@
|
||||
// We mean it.
|
||||
//
|
||||
|
||||
#include <QtCore/qglobal.h>
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
#include <private/qobject_p.h>
|
||||
#include <QtCore/qabstractstate.h>
|
||||
|
||||
QT_REQUIRE_CONFIG(statemachine);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QStateMachine;
|
||||
@ -98,6 +96,4 @@ public:
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif // QT_NO_STATEMACHINE
|
||||
|
||||
#endif // QABSTRACTSTATE_P_H
|
||||
|
@ -38,9 +38,6 @@
|
||||
****************************************************************************/
|
||||
|
||||
#include "qabstracttransition.h"
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
#include "qabstracttransition_p.h"
|
||||
#include "qabstractstate.h"
|
||||
#include "qhistorystate.h"
|
||||
@ -434,5 +431,3 @@ bool QAbstractTransition::event(QEvent *e)
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
@ -44,11 +44,10 @@
|
||||
|
||||
#include <QtCore/qlist.h>
|
||||
|
||||
QT_REQUIRE_CONFIG(statemachine);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
class QEvent;
|
||||
class QAbstractState;
|
||||
class QState;
|
||||
@ -113,8 +112,6 @@ private:
|
||||
Q_DECLARE_PRIVATE(QAbstractTransition)
|
||||
};
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
@ -57,6 +57,8 @@
|
||||
#include <QtCore/qvector.h>
|
||||
#include <QtCore/qsharedpointer.h>
|
||||
|
||||
QT_REQUIRE_CONFIG(statemachine);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QAbstractState;
|
||||
|
@ -38,9 +38,6 @@
|
||||
****************************************************************************/
|
||||
|
||||
#include "qeventtransition.h"
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
#include "qeventtransition_p.h"
|
||||
#include "qstate.h"
|
||||
#include "qstate_p.h"
|
||||
@ -255,5 +252,3 @@ bool QEventTransition::event(QEvent *e)
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
@ -43,11 +43,10 @@
|
||||
#include <QtCore/qabstracttransition.h>
|
||||
#include <QtCore/qcoreevent.h>
|
||||
|
||||
QT_REQUIRE_CONFIG(qeventtransition);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
class QEventTransitionPrivate;
|
||||
class Q_CORE_EXPORT QEventTransition : public QAbstractTransition
|
||||
{
|
||||
@ -81,8 +80,6 @@ private:
|
||||
Q_DECLARE_PRIVATE(QEventTransition)
|
||||
};
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
@ -53,6 +53,8 @@
|
||||
|
||||
#include "private/qabstracttransition_p.h"
|
||||
|
||||
QT_REQUIRE_CONFIG(qeventtransition);
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QEventTransition;
|
||||
|
@ -39,8 +39,6 @@
|
||||
|
||||
#include "qfinalstate_p.h"
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
/*!
|
||||
@ -139,5 +137,3 @@ bool QFinalState::event(QEvent *e)
|
||||
}
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
@ -42,9 +42,9 @@
|
||||
|
||||
#include <QtCore/qabstractstate.h>
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
QT_REQUIRE_CONFIG(statemachine);
|
||||
|
||||
#ifndef QT_NO_STATEMACHINE
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
class QFinalStatePrivate;
|
||||
class Q_CORE_EXPORT QFinalState : public QAbstractState
|
||||
@ -68,8 +68,6 @@ private:
|
||||
Q_DECLARE_PRIVATE(QFinalState)
|
||||
};
|
||||
|
||||
#endif //QT_NO_STATEMACHINE
|
||||
|
||||
QT_END_NAMESPACE
|
||||
|
||||
#endif
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user