]> git.saurik.com Git - wxWidgets.git/blobdiff - src/stc/stc.cpp.in
Disable handling of wxEVT_MOUSEWHEEL in wxVarScrollHelperEvtHandler in wxGTK.
[wxWidgets.git] / src / stc / stc.cpp.in
index d63a1f9fc428c0a9ba69b1209085a2accfe2d3ce..6b5e34d486c7d5efa95da8f09cd52473f118a8ba 100644 (file)
@@ -10,7 +10,6 @@
 // Author:      Robin Dunn
 //
 // Created:     13-Jan-2000
-// RCS-ID:      $Id$
 // Copyright:   (c) 2000 by Total Control Software
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 #if wxUSE_FFILE
     #include "wx/ffile.h"
 #elif wxUSE_FILE
-    #include "wx/ffile.h"
+    #include "wx/file.h"
+#endif
+
+#ifdef __WXGTK__
+    #include "wx/dcbuffer.h"
 #endif
 
 #include "ScintillaWX.h"
@@ -521,7 +524,7 @@ void wxStyledTextCtrl::DoSetValue(const wxString& value, int flags)
     else
         SetText(value);
 
-    // We don't send wxEVT_COMMAND_TEXT_UPDATED anyhow, so ignore the
+    // We don't send wxEVT_TEXT anyhow, so ignore the
     // SetValue_SendEvent bit of the flags
 }
 
@@ -567,7 +570,7 @@ wxStyledTextCtrl::DoLoadFile(const wxString& filename, int WXUNUSED(fileType))
     if ( file.IsOpened() )
     {
         wxString text;
-        if ( file.ReadAll(&text, *wxConvCurrent) )
+        if ( file.ReadAll(&text, wxConvAuto()) )
         {
             // Detect the EOL: we use just the first line because there is not
             // much we can do if the file uses inconsistent EOLs anyhow, we'd
@@ -643,7 +646,7 @@ bool wxStyledTextCtrl::GetUseAntiAliasing() {
 }
 
 void wxStyledTextCtrl::AnnotationClearLine(int line) {
-    SendMsg(SCI_ANNOTATIONSETTEXT, line, NULL);
+    SendMsg(SCI_ANNOTATIONSETTEXT, line, (sptr_t)NULL);
 }
 
 
@@ -750,7 +753,11 @@ void wxStyledTextCtrl::AppendTextRaw(const char* text, int length)
 // Event handlers
 
 void wxStyledTextCtrl::OnPaint(wxPaintEvent& WXUNUSED(evt)) {
+#ifdef __WXGTK__
+    wxBufferedPaintDC dc(this);
+#else
     wxPaintDC dc(this);
+#endif
     m_swx->DoPaint(&dc, GetUpdateRegion().GetBox());
 }
 
@@ -825,9 +832,11 @@ void wxStyledTextCtrl::OnContextMenu(wxContextMenuEvent& evt) {
 
 void wxStyledTextCtrl::OnMouseWheel(wxMouseEvent& evt)
 {
-    m_swx->DoMouseWheel(evt.GetWheelRotation(),
+    m_swx->DoMouseWheel(evt.GetWheelAxis(),
+                        evt.GetWheelRotation(),
                         evt.GetWheelDelta(),
                         evt.GetLinesPerAction(),
+                        evt.GetColumnsPerAction(),
                         evt.ControlDown(),
                         evt.IsPageScroll());
 }