OSDN Git Service
(root)
/
qt-creator-jp
/
qt-creator-jp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aa5d5c6
)
Fix crash after removing target
author
dt
<qtc-committer@nokia.com>
Mon, 9 May 2011 12:16:19 +0000
(14:16 +0200)
committer
dt
<qtc-committer@nokia.com>
Mon, 9 May 2011 18:53:19 +0000
(20:53 +0200)
Reported on irc by ckamm
src/plugins/projectexplorer/targetselector.cpp
patch
|
blob
|
history
diff --git
a/src/plugins/projectexplorer/targetselector.cpp
b/src/plugins/projectexplorer/targetselector.cpp
index
bd41c22
..
dcb0618
100644
(file)
--- a/
src/plugins/projectexplorer/targetselector.cpp
+++ b/
src/plugins/projectexplorer/targetselector.cpp
@@
-91,9
+91,7
@@
void TargetSelector::removeTarget(int index)
m_targets.removeAt(index);
- if (m_currentTargetIndex >= m_targets.count()) {
- setCurrentIndex(-1);
- } else if (m_currentTargetIndex >= index) {
+ if (m_currentTargetIndex > index) {
--m_currentTargetIndex;
// force a signal since the index has changed
emit currentChanged(m_currentTargetIndex, m_targets.at(m_currentTargetIndex).currentSubIndex);