Skip to content
GitLab
Menu
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
a71fcf63
Commit
a71fcf63
authored
Jan 28, 2009
by
con
Browse files
Fixes: - Funny cursor positions in qrc editor.
parent
2dac5e64
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/shared/qrceditor/qrceditor.cpp
View file @
a71fcf63
...
...
@@ -151,21 +151,28 @@ void QrcEditor::updateCurrent()
const
bool
isValid
=
m_treeview
->
currentIndex
().
isValid
();
const
bool
isPrefix
=
m_treeview
->
isPrefix
(
m_treeview
->
currentIndex
())
&&
isValid
;
const
bool
isFile
=
!
isPrefix
&&
isValid
;
int
cursorPosition
;
m_ui
.
aliasLabel
->
setEnabled
(
isFile
);
m_ui
.
aliasText
->
setEnabled
(
isFile
);
m_currentAlias
=
m_treeview
->
currentAlias
();
cursorPosition
=
m_ui
.
aliasText
->
cursorPosition
();
m_ui
.
aliasText
->
setText
(
m_currentAlias
);
m_ui
.
aliasText
->
setCursorPosition
(
cursorPosition
);
m_ui
.
prefixLabel
->
setEnabled
(
isPrefix
);
m_ui
.
prefixText
->
setEnabled
(
isPrefix
);
m_currentPrefix
=
m_treeview
->
currentPrefix
();
cursorPosition
=
m_ui
.
prefixText
->
cursorPosition
();
m_ui
.
prefixText
->
setText
(
m_currentPrefix
);
m_ui
.
prefixText
->
setCursorPosition
(
cursorPosition
);
m_ui
.
languageLabel
->
setEnabled
(
isPrefix
);
m_ui
.
languageText
->
setEnabled
(
isPrefix
);
m_currentLanguage
=
m_treeview
->
currentLanguage
();
cursorPosition
=
m_ui
.
languageText
->
cursorPosition
();
m_ui
.
languageText
->
setText
(
m_currentLanguage
);
m_ui
.
languageText
->
setCursorPosition
(
cursorPosition
);
m_ui
.
addButton
->
setEnabled
(
true
);
m_addFileAction
->
setEnabled
(
isValid
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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