Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Marco Bubke
flatpak-qt-creator
Commits
19190384
Commit
19190384
authored
Apr 14, 2011
by
Christiaan Janssen
Browse files
QmlProfiler: user defined host:port
Reviewed-by: Kai Koehne
parent
fa2b2942
Changes
5
Hide whitespace changes
Inline
Side-by-side
src/plugins/analyzerbase/analyzerruncontrolfactory.cpp
View file @
19190384
...
...
@@ -61,6 +61,8 @@ AnalyzerStartParameters localStartParameters(ProjectExplorer::RunConfiguration *
sp
.
debuggee
=
rc
->
executable
();
sp
.
debuggeeArgs
=
rc
->
commandLineArguments
();
sp
.
displayName
=
rc
->
displayName
();
sp
.
connParams
.
host
=
QLatin1String
(
"localhost"
);
sp
.
connParams
.
port
=
rc
->
qmlDebugServerPort
();
return
sp
;
}
...
...
src/plugins/qmlprofiler/qmlprofilerengine.cpp
View file @
19190384
...
...
@@ -147,7 +147,7 @@ bool QmlProfilerEngine::QmlProfilerEnginePrivate::launchperfmonitor()
m_process
=
new
QProcess
();
QStringList
arguments
(
"-qmljsdebugger=port:"
+
QString
::
number
(
QmlProfilerTool
::
port
)
+
",block"
);
QStringList
arguments
(
"-qmljsdebugger=port:"
+
QString
::
number
(
m_params
.
connParams
.
port
)
+
",block"
);
arguments
.
append
(
m_params
.
debuggeeArgs
.
split
(
" "
));
if
(
QmlProfilerPlugin
::
debugOutput
)
...
...
@@ -174,7 +174,7 @@ bool QmlProfilerEngine::QmlProfilerEnginePrivate::launchperfmonitor()
}
if
(
QmlProfilerPlugin
::
debugOutput
)
qWarning
(
"QmlProfiler: Connecting to %s:%d"
,
qPrintable
(
QmlProfilerTool
::
host
),
QmlProfilerTool
::
port
);
qWarning
(
"QmlProfiler: Connecting to %s:%d"
,
qPrintable
(
m_params
.
connParams
.
host
),
m_params
.
connParams
.
port
);
return
true
;
}
...
...
src/plugins/qmlprofiler/qmlprofilertool.cpp
View file @
19190384
...
...
@@ -76,10 +76,6 @@
using
namespace
Analyzer
;
using
namespace
QmlProfiler
::
Internal
;
QString
QmlProfilerTool
::
host
=
QLatin1String
(
"localhost"
);
quint16
QmlProfilerTool
::
port
=
33456
;
// Adapter for output pane.
class
QmlProfilerOutputPaneAdapter
:
public
Analyzer
::
IAnalyzerOutputPaneAdapter
{
...
...
@@ -124,6 +120,8 @@ public:
QAction
*
m_attachAction
;
QToolButton
*
m_recordButton
;
bool
m_recordingEnabled
;
QString
m_host
;
quint64
m_port
;
};
QmlProfilerTool
::
QmlProfilerTool
(
QObject
*
parent
)
...
...
@@ -170,6 +168,9 @@ IAnalyzerEngine *QmlProfilerTool::createEngine(const AnalyzerStartParameters &sp
{
QmlProfilerEngine
*
engine
=
new
QmlProfilerEngine
(
sp
,
runConfiguration
);
d
->
m_host
=
sp
.
connParams
.
host
;
d
->
m_port
=
sp
.
connParams
.
port
;
d
->
m_runConfiguration
=
runConfiguration
;
d
->
m_project
=
runConfiguration
->
target
()
->
project
();
if
(
d
->
m_project
)
{
...
...
@@ -291,7 +292,7 @@ void QmlProfilerTool::connectClient()
delete
d
->
m_client
;
d
->
m_client
=
newClient
;
d
->
m_client
->
connectToHost
(
host
,
port
);
d
->
m_client
->
connectToHost
(
d
->
m_
host
,
d
->
m_
port
);
d
->
m_client
->
waitForConnected
();
if
(
d
->
m_client
->
isConnected
())
{
...
...
@@ -392,8 +393,8 @@ void QmlProfilerTool::attach()
if
(
result
==
QDialog
::
Rejected
)
return
;
port
=
dialog
.
port
();
host
=
dialog
.
address
();
d
->
m_
port
=
dialog
.
port
();
d
->
m_
host
=
dialog
.
address
();
connectClient
();
AnalyzerManager
::
instance
()
->
showMode
();
...
...
src/plugins/qmlprofiler/qmlprofilertool.h
View file @
19190384
...
...
@@ -81,11 +81,6 @@ signals:
void
fetchingData
(
bool
);
void
connectionFailed
();
public:
// Todo: configurable parameters
static
QString
host
;
static
quint16
port
;
private
slots
:
void
updateProjectFileList
();
void
attach
();
...
...
src/plugins/qmlprofiler/qmlprojectanalyzerruncontrolfactory.cpp
View file @
19190384
...
...
@@ -57,6 +57,8 @@ AnalyzerStartParameters localStartParameters(ProjectExplorer::RunConfiguration *
sp
.
debuggee
=
rc
->
observerPath
();
sp
.
debuggeeArgs
=
rc
->
viewerArguments
();
sp
.
displayName
=
rc
->
displayName
();
sp
.
connParams
.
host
=
QLatin1String
(
"localhost"
);
sp
.
connParams
.
port
=
rc
->
qmlDebugServerPort
();
return
sp
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment