~sil2100/ubuntu-keyboard/key_sound_on_all_keys

« back to all changes in this revision

Viewing changes to src/view/setup.cpp

  • Committer: Tarmac
  • Author(s): Thomas Moenicke, Bill Filler
  • Date: 2014-01-27 12:26:37 UTC
  • mfrom: (121.2.17 ubuntu-keyboard-legacy)
  • Revision ID: tarmac-20140127122637-5ekbjfm8rwxueao8
Remove legacy code and files: the old language xml files, deprecated LayoutUpdater usage, old layouting.

Approved by PS Jenkins bot, Łukasz Zemczak.

Show diffs side-by-side

added added

removed removed

Lines of Context:
37
37
#include "models/wordcandidate.h"
38
38
#include "models/text.h"
39
39
 
40
 
#include "logic/layouthelper.h"
 
40
//#include "logic/layouthelper.h"
41
41
#include "logic/layoutupdater.h"
42
42
#include "logic/eventhandler.h"
43
43
 
45
45
namespace Setup {
46
46
 
47
47
void connectAll(Logic::EventHandler *event_handler,
48
 
                Logic::LayoutUpdater *updater,
49
48
                AbstractTextEditor *editor)
50
49
{
51
50
    connectEventHandlerToTextEditor(event_handler, editor);
52
 
    connectLayoutUpdaterToTextEditor(updater, editor);
53
51
}
54
52
 
55
53
void connectEventHandlerToTextEditor(Logic::EventHandler *event_handler,
60
58
 
61
59
    QObject::connect(event_handler, SIGNAL(keyReleased(Key)),
62
60
                     editor,        SLOT(onKeyReleased(Key)));
63
 
 
64
 
    QObject::connect(event_handler, SIGNAL(keyEntered(Key)),
65
 
                     editor,        SLOT(onKeyEntered(Key)));
66
 
 
67
 
    QObject::connect(event_handler, SIGNAL(keyExited(Key)),
68
 
                     editor,        SLOT(onKeyExited(Key)));
69
 
}
70
 
 
71
 
void connectLayoutUpdaterToTextEditor(Logic::LayoutUpdater *updater,
72
 
                                      AbstractTextEditor *editor)
73
 
{
74
 
    QObject::connect(updater, SIGNAL(wordCandidateSelected(QString)),
75
 
                     editor,  SLOT(replaceAndCommitPreedit(QString)));
76
 
 
77
 
    QObject::connect(updater, SIGNAL(addToUserDictionary()),
78
 
                     editor,  SLOT(showUserCandidate()));
79
 
 
80
 
    QObject::connect(updater, SIGNAL(userCandidateSelected(QString)),
81
 
                     editor,  SLOT(addToUserDictionary(QString)));
82
 
 
83
 
    QObject::connect(editor,  SIGNAL(preeditEnabledChanged(bool)),
84
 
                     updater, SLOT(setWordRibbonVisible(bool)));
85
 
 
86
 
    QObject::connect(editor,  SIGNAL(wordCandidatesChanged(WordCandidateList)),
87
 
                     updater, SLOT(onWordCandidatesChanged(WordCandidateList)));
88
 
 
89
 
    QObject::connect(editor,  SIGNAL(autoCapsActivated()),
90
 
                     updater, SIGNAL(autoCapsActivated()));
91
 
}
92
 
 
 
61
}
93
62
}} // namespace Setup, MaliitKeyboard