]> git.saurik.com Git - wxWidgets.git/commitdiff
Always use wxHSCROLL|wxVSCROLL.
authorRobin Dunn <robin@alldunn.com>
Mon, 2 Apr 2007 21:15:27 +0000 (21:15 +0000)
committerRobin Dunn <robin@alldunn.com>
Mon, 2 Apr 2007 21:15:27 +0000 (21:15 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45219 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

contrib/src/stc/stc.cpp
contrib/src/stc/stc.cpp.in
src/stc/stc.cpp
src/stc/stc.cpp.in

index 3b7d9bfc8f0976f2f75c83a17ebc0fb92ad3e857..7cde4f12f2f79266cf20b8e9d21d738fffe1ddb2 100644 (file)
@@ -158,9 +158,7 @@ bool wxStyledTextCtrl::Create(wxWindow *parent,
                               long style,
                               const wxString& name)
 {
-#ifdef __WXMAC__
     style |= wxVSCROLL | wxHSCROLL;
-#endif
     if (!wxControl::Create(parent, id, pos, size,
                            style | wxWANTS_CHARS | wxCLIP_CHILDREN,
                            wxDefaultValidator, name))
@@ -3118,6 +3116,13 @@ void wxStyledTextCtrl::OnChar(wxKeyEvent& evt) {
 #endif
     bool skip = ((ctrl || alt) && ! (ctrl && alt));
 
+#if wxUSE_UNICODE
+    // apparently if we don't do this, Unicode keys pressed after non-char
+    // ASCII ones (e.g. Enter, Tab) are not taken into account (patch 1615989)
+    if (m_lastKeyDownConsumed && evt.GetUnicodeKey() > 255)
+        m_lastKeyDownConsumed = false;
+#endif
+
     if (!m_lastKeyDownConsumed && !skip) {
 #if wxUSE_UNICODE
         int key = evt.GetUnicodeKey();
index af1773ddeb90ccc3a90e209fbc1c41690b202be6..8275b92ce7941c456460f54aa1e4639b31f638ba 100644 (file)
@@ -158,9 +158,7 @@ bool wxStyledTextCtrl::Create(wxWindow *parent,
                               long style,
                               const wxString& name)
 {
-#ifdef __WXMAC__
     style |= wxVSCROLL | wxHSCROLL;
-#endif
     if (!wxControl::Create(parent, id, pos, size,
                            style | wxWANTS_CHARS | wxCLIP_CHILDREN,
                            wxDefaultValidator, name))
index 3b7d9bfc8f0976f2f75c83a17ebc0fb92ad3e857..7cde4f12f2f79266cf20b8e9d21d738fffe1ddb2 100644 (file)
@@ -158,9 +158,7 @@ bool wxStyledTextCtrl::Create(wxWindow *parent,
                               long style,
                               const wxString& name)
 {
-#ifdef __WXMAC__
     style |= wxVSCROLL | wxHSCROLL;
-#endif
     if (!wxControl::Create(parent, id, pos, size,
                            style | wxWANTS_CHARS | wxCLIP_CHILDREN,
                            wxDefaultValidator, name))
@@ -3118,6 +3116,13 @@ void wxStyledTextCtrl::OnChar(wxKeyEvent& evt) {
 #endif
     bool skip = ((ctrl || alt) && ! (ctrl && alt));
 
+#if wxUSE_UNICODE
+    // apparently if we don't do this, Unicode keys pressed after non-char
+    // ASCII ones (e.g. Enter, Tab) are not taken into account (patch 1615989)
+    if (m_lastKeyDownConsumed && evt.GetUnicodeKey() > 255)
+        m_lastKeyDownConsumed = false;
+#endif
+
     if (!m_lastKeyDownConsumed && !skip) {
 #if wxUSE_UNICODE
         int key = evt.GetUnicodeKey();
index af1773ddeb90ccc3a90e209fbc1c41690b202be6..8275b92ce7941c456460f54aa1e4639b31f638ba 100644 (file)
@@ -158,9 +158,7 @@ bool wxStyledTextCtrl::Create(wxWindow *parent,
                               long style,
                               const wxString& name)
 {
-#ifdef __WXMAC__
     style |= wxVSCROLL | wxHSCROLL;
-#endif
     if (!wxControl::Create(parent, id, pos, size,
                            style | wxWANTS_CHARS | wxCLIP_CHILDREN,
                            wxDefaultValidator, name))