If there are other editors on the document visible in some split, it
should not close the document, but only the editor.
Task-number: QTCREATORBUG-9346
Change-Id: Idce1ae2f518d4c6e875d86f9831d41c46c06361c
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Following the new simple-factory pattern
Change-Id: Idceb7a339169af37a040f9da7d36d3fe22dfb347
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
The VCS plugins keep a reference to the submit editor, so it can
explicitly be closed, instead of relying on the correct currentEditor in
the editor manager.
Change-Id: I14aab63447f790f2065a8d8dc6b50aeacbd1e941
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
There was document(), textDocument() and baseTextDocument().
Two should be enough...
Change-Id: Id9e41c8d857c5cb3269a9fce5ab594d34448c982
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
This change has lead to complaints about diff views opening
in apparently random places for users with several splits.
This reverts commit 02b3a79c5f.
Conflicts:
src/plugins/diffeditor/diffeditorplugin.cpp
src/plugins/subversion/subversionplugin.cpp
Change-Id: I2eab8ff2d88a9e12f4dc7ec3a9ca65455daf15e2
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
... if there are other splits that is.
Task-number: QTCREATORBUG-11623
Change-Id: Icb3b1c86c39d88e90916079e8ab347574ae9a361
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This requires moving the activateEditor call into openEditorWithContents.
Remove that line elsewhere when editors are constructed. Keep it when
reusing an existing editor though.
Change-Id: I872f03e16fde42f3b8adec2cf2344b7cc495cd08
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Required for supporting renames on annotate.
The renamed file (and possibly its parent directory) doesn't exist
anymore, so it shouldn't be passed as a working directory.
Change-Id: I809e8df17c1dc5199e533b525244a668eccbcd5f
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Also adjust and streamline using and surrounding code.
Change-Id: I6a8b05126bdcbb74ff611b21c7cb3c5902a2d5ca
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Command now provides the same functionality. Deduplicate code.
Change-Id: I789f021050471281870b6ef6a81a94e66fbdf0c7
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
* Introduce a proxy class for thread synchronization
* Use signals for appending text to output window
Change-Id: Iecbb010e6b6e9dab27d9862a43dafa450f2bb1f8
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
The list always contains a single entry (or none) anyway
Take 2. This time it actually compiles ;-)
Change-Id: I71a9822360a9b569ba79afa0f575e27918bb2e03
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
And use it where appropriate
Change-Id: I0f37b8aada6eaa9be6743724b91a59173a01cb0c
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: David Schulz <david.schulz@digia.com>
The method is for setting the contents, so it belongs to the document,
and should be named correspondingly.
Change-Id: I40363dc08f11268f530885b512e4a88e8b10d096
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
That is what it actually is, wrt how Qt API calls it.
Change-Id: Ied02055debf6aad75556b0d9d22e8ba2f72be555
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This change
* Removes IMode::type, ModeManager::activateModeType, and
IEditor::preferredModeType, and adds IEditor::isDesignModePreferred
instead
* Adapts the mode switching code in EditorManager to handle multiple
windows, for example switching to edit mode should only happen if
the editor/view is in the main window. Otherwise the editor window
should be raised and focused
* Renames EditorManager::NoActivate --> DoNotChangeCurrentEditor
* Reverts the EditorManager::ModeSwitch logic to switch mode or
make the current editor visible by default, introducing
DoNotMakeVisible flag instead
* Fixes a few instances where EditorManager::ModeSwitch should have been
used
One non-trivial problem left: If you open a .ui file and switch to an
external editor window, edit mode is activated, because the current
editor no longer is a .ui file, which means that the design mode gets
deactivated.
Change-Id: I76c5c2391eb4090143b778fb103acff3a5a1ff41
Reviewed-by: David Schulz <david.schulz@digia.com>
This is still way too much boiler plate code for the task at hand.
Change-Id: Ia03bff3d6947ea6372e3f5d0217c116728742b74
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
It was not possible to simultaneously open two commit editors for
different version control systems, also there was no reason to scan all
open editors for the submit editor, since the plugins can just remember
the editor that they opened.
Change-Id: I1bea6ece3cd6faa1ecc0566bdd6f5fb10c816963
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This was mostly used to disambiguate the char * and the QString
constructors.
Change-Id: Ib6923ef8e8c0e5d514a883e73aa001a1cd9fb534
Reviewed-by: Eike Ziller <eike.ziller@digia.com>