forked from qt-creator/qt-creator
TextEditor: Allow using CodecSelector with BaseTextDocuments
Task-number: QTCREATORBUG-23835 Change-Id: I56133dbf22fdae9f2fec37d0ffd2a35de5fb1ad5 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -58,7 +58,7 @@ public:
|
|||||||
} // namespace TextEditor
|
} // namespace TextEditor
|
||||||
|
|
||||||
|
|
||||||
CodecSelector::CodecSelector(QWidget *parent, TextDocument *doc)
|
CodecSelector::CodecSelector(QWidget *parent, Core::BaseTextDocument *doc)
|
||||||
: QDialog(parent)
|
: QDialog(parent)
|
||||||
{
|
{
|
||||||
m_hasDecodingError = doc->hasDecodingError();
|
m_hasDecodingError = doc->hasDecodingError();
|
||||||
|
@@ -31,11 +31,9 @@
|
|||||||
#include <QListWidget>
|
#include <QListWidget>
|
||||||
|
|
||||||
namespace Utils { class ListWidget; }
|
namespace Utils { class ListWidget; }
|
||||||
|
namespace Core { class BaseTextDocument; }
|
||||||
|
|
||||||
namespace TextEditor {
|
namespace TextEditor {
|
||||||
|
|
||||||
class TextDocument;
|
|
||||||
|
|
||||||
namespace Internal {
|
namespace Internal {
|
||||||
|
|
||||||
class CodecSelector : public QDialog
|
class CodecSelector : public QDialog
|
||||||
@@ -44,7 +42,7 @@ class CodecSelector : public QDialog
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
CodecSelector(QWidget *parent, TextDocument *doc);
|
CodecSelector(QWidget *parent, Core::BaseTextDocument *doc);
|
||||||
~CodecSelector() override;
|
~CodecSelector() override;
|
||||||
|
|
||||||
QTextCodec *selectedCodec() const;
|
QTextCodec *selectedCodec() const;
|
||||||
|
Reference in New Issue
Block a user