Qnx: Remove unneeded qualifications

Mostly done using the following ruby script:
Dir.glob('**/*.cpp').each { |file|
  next if file =~ %r{src/shared/qbs|/qmljs/}
  s = File.read(file)
  s.scan(/^using namespace (.*);$/) {
    ns = $1
    t = s.gsub(/^(.*)\b#{ns}::((?!Const)[A-Z])/) { |m|
      before = $1
      char = $2
      if before =~ /"|\/\/|\\|using|SIGNAL|SLOT|Q_/
        m
      else
        before + char
      end
    }
    if t != s
      puts file
      File.open(file, 'w').write(t)
    end
  }
}

Change-Id: I78a70180927d085822e215ffb2b8ad256301e4a7
Reviewed-by: hjk <hjk@theqtcompany.com>
This commit is contained in:
Orgad Shaneh
2015-02-03 23:51:12 +02:00
committed by hjk
parent b001e54599
commit b1c17b39bc
11 changed files with 70 additions and 71 deletions

View File

@@ -95,7 +95,7 @@ void QnxDeviceProcess::doSignal(int sig)
}
class QnxPortsGatheringMethod : public ProjectExplorer::PortsGatheringMethod
class QnxPortsGatheringMethod : public PortsGatheringMethod
{
// TODO: The command is probably needlessly complicated because the parsing method
// used to be fixed. These two can now be matched to each other.
@@ -177,7 +177,7 @@ int QnxDeviceConfiguration::qnxVersion() const
void QnxDeviceConfiguration::updateVersionNumber() const
{
QEventLoop eventLoop;
ProjectExplorer::SshDeviceProcess versionNumberProcess(sharedFromThis());
SshDeviceProcess versionNumberProcess(sharedFromThis());
QObject::connect(&versionNumberProcess, SIGNAL(finished()), &eventLoop, SLOT(quit()));
QObject::connect(&versionNumberProcess, SIGNAL(error(QProcess::ProcessError)), &eventLoop, SLOT(quit()));
@@ -218,27 +218,27 @@ QVariantMap QnxDeviceConfiguration::toMap() const
return map;
}
ProjectExplorer::IDevice::Ptr QnxDeviceConfiguration::clone() const
IDevice::Ptr QnxDeviceConfiguration::clone() const
{
return Ptr(new QnxDeviceConfiguration(*this));
}
ProjectExplorer::PortsGatheringMethod::Ptr QnxDeviceConfiguration::portsGatheringMethod() const
PortsGatheringMethod::Ptr QnxDeviceConfiguration::portsGatheringMethod() const
{
return ProjectExplorer::PortsGatheringMethod::Ptr(new QnxPortsGatheringMethod);
return PortsGatheringMethod::Ptr(new QnxPortsGatheringMethod);
}
ProjectExplorer::DeviceProcessList *QnxDeviceConfiguration::createProcessListModel(QObject *parent) const
DeviceProcessList *QnxDeviceConfiguration::createProcessListModel(QObject *parent) const
{
return new QnxDeviceProcessList(sharedFromThis(), parent);
}
ProjectExplorer::DeviceTester *QnxDeviceConfiguration::createDeviceTester() const
DeviceTester *QnxDeviceConfiguration::createDeviceTester() const
{
return new QnxDeviceTester;
}
ProjectExplorer::DeviceProcess *QnxDeviceConfiguration::createProcess(QObject *parent) const
DeviceProcess *QnxDeviceConfiguration::createProcess(QObject *parent) const
{
return new QnxDeviceProcess(sharedFromThis(), parent);
}
@@ -270,9 +270,9 @@ void QnxDeviceConfiguration::executeAction(Core::Id actionId, QWidget *parent)
}
}
ProjectExplorer::DeviceProcessSignalOperation::Ptr QnxDeviceConfiguration::signalOperation() const
DeviceProcessSignalOperation::Ptr QnxDeviceConfiguration::signalOperation() const
{
return ProjectExplorer::DeviceProcessSignalOperation::Ptr(
return DeviceProcessSignalOperation::Ptr(
new QnxDeviceProcessSignalOperation(sshParameters()));
}