From 2307a07f6483d64e50b0203b1948f42e6fab86dc Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Wed, 13 Sep 2017 11:59:21 +0200 Subject: Use the switch --- components/kube/contents/ui/ComposerView.qml | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'components') diff --git a/components/kube/contents/ui/ComposerView.qml b/components/kube/contents/ui/ComposerView.qml index 29858767..34a2f56c 100644 --- a/components/kube/contents/ui/ComposerView.qml +++ b/components/kube/contents/ui/ComposerView.qml @@ -272,10 +272,9 @@ Kube.View { spacing: Kube.Units.largeSpacing - Kube.Button { + Kube.Switch { id: html text: checked ? qsTr("plain") : qsTr("html") - checkable: true focusPolicy: Qt.TabFocus focus: false } @@ -347,14 +346,6 @@ Kube.View { onActiveFocusChanged: closeFirstSplitIfNecessary() Keys.onEscapePressed: recipients.forceActiveFocus() initialText: composerController.body - /** - * We need to: - * * initially load the text from the controller (for replies and whatnot) - * * Then only read from documenthandler in either html or plain (depending on the format). - * * Convert between html and plain when switching the format. - * * Skip invisible chars - * * Remove invisible chars from copied text somehow - */ onTextChanged: composerController.body = text; } } -- cgit v1.2.3