X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/c26400bd067ce812a7dd3b090dce0928b8b0e80e..567e5e47ee9af2f6e7343cb94bd890a3a6104f1e:/src/stc/ScintillaWX.cpp?ds=sidebyside diff --git a/src/stc/ScintillaWX.cpp b/src/stc/ScintillaWX.cpp index 3e384177bb..6d6856895b 100644 --- a/src/stc/ScintillaWX.cpp +++ b/src/stc/ScintillaWX.cpp @@ -1,5 +1,5 @@ //////////////////////////////////////////////////////////////////////////// -// Name: ScintillaWX.cxx +// Name: src/stc/ScintillaWX.cpp // Purpose: A wxWidgets implementation of Scintilla. A class derived // from ScintillaBase that uses the "wx platform" defined in // PlatformWX.cxx This class is one end of a bridge between @@ -11,7 +11,7 @@ // Created: 13-Jan-2000 // RCS-ID: $Id$ // Copyright: (c) 2000 by Total Control Software -// Licence: wxWindows license +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// // For compilers that support precompilation, includes "wx.h". @@ -34,6 +34,12 @@ #include "wx/clipbrd.h" #include "wx/dnd.h" +#if !wxUSE_STD_CONTAINERS && !wxUSE_STD_IOSTREAM && !wxUSE_STD_STRING + #include "wx/beforestd.h" + #include + #include "wx/afterstd.h" +#endif + #include "ScintillaWX.h" #include "ExternalLexer.h" #include "wx/stc/stc.h" @@ -283,13 +289,13 @@ void ScintillaWX::StartDrag() { wxStyledTextEvent evt(wxEVT_STC_START_DRAG, stc->GetId()); evt.SetEventObject(stc); evt.SetDragText(dragText); - evt.SetDragAllowMove(true); + evt.SetDragFlags(wxDrag_DefaultMove); evt.SetPosition(wxMin(stc->GetSelectionStart(), stc->GetSelectionEnd())); stc->GetEventHandler()->ProcessEvent(evt); dragText = evt.GetDragText(); - if (dragText.length()) { + if ( !dragText.empty() ) { wxDropSource source(stc); wxTextDataObject data(dragText); wxDragResult result; @@ -297,7 +303,7 @@ void ScintillaWX::StartDrag() { source.SetData(data); dropWentOutside = true; inDragDrop = ddDragging; - result = source.DoDragDrop(evt.GetDragAllowMove()); + result = source.DoDragDrop(evt.GetDragFlags()); if (result == wxDragMove && dropWentOutside) ClearSelection(); inDragDrop = ddNone; @@ -1068,9 +1074,7 @@ void ScintillaWX::DoDragLeave() { // Force the whole window to be repainted void ScintillaWX::FullPaint() { -#ifndef __WXMAC__ stc->Refresh(false); -#endif stc->Update(); }