20 #ifdef EDITOR_HOOK_PERFORMANCE_MEASURE    25 #endif // EDITOR_HOOK_PERFORMANCE_MEASURE    32 #ifdef EDITOR_HOOK_PERFORMANCE_MEASURE    37     if (type == wxEVT_SCI_CHANGE)                  name = 
_T(
"wxEVT_SCI_CHANGE");
    38     else if (type == wxEVT_SCI_STYLENEEDED)        name = 
_T(
"wxEVT_SCI_STYLENEEDED");
    39     else if (type == wxEVT_SCI_CHARADDED)          name = 
_T(
"wxEVT_SCI_CHARADDED");
    40     else if (type == wxEVT_SCI_SAVEPOINTREACHED)   name = 
_T(
"wxEVT_SCI_SAVEPOINTREACHED");
    41     else if (type == wxEVT_SCI_SAVEPOINTLEFT)      name = 
_T(
"wxEVT_SCI_SAVEPOINTLEFT");
    42     else if (type == wxEVT_SCI_ROMODIFYATTEMPT)    name = 
_T(
"wxEVT_SCI_ROMODIFYATTEMPT");
    43     else if (type == wxEVT_SCI_KEY)                name = 
_T(
"wxEVT_SCI_KEY");
    44     else if (type == wxEVT_SCI_DOUBLECLICK)        name = 
_T(
"wxEVT_SCI_DOUBLECLICK");
    45     else if (type == wxEVT_SCI_UPDATEUI)           name = 
_T(
"wxEVT_SCI_UPDATEUI");
    46     else if (type == wxEVT_SCI_MODIFIED)           name = 
_T(
"wxEVT_SCI_MODIFIED");
    47     else if (type == wxEVT_SCI_MACRORECORD)        name = 
_T(
"wxEVT_SCI_MACRORECORD");
    48     else if (type == wxEVT_SCI_MARGINCLICK)        name = 
_T(
"wxEVT_SCI_MARGINCLICK");
    49     else if (type == wxEVT_SCI_NEEDSHOWN)          name = 
_T(
"wxEVT_SCI_NEEDSHOWN");
    50     else if (type == wxEVT_SCI_PAINTED)            name = 
_T(
"wxEVT_SCI_PAINTED");
    51     else if (type == wxEVT_SCI_USERLISTSELECTION)  name = 
_T(
"wxEVT_SCI_USERLISTSELECTION");
    52     else if (type == wxEVT_SCI_URIDROPPED)         name = 
_T(
"wxEVT_SCI_URIDROPPED");
    53     else if (type == wxEVT_SCI_DWELLSTART)         name = 
_T(
"wxEVT_SCI_DWELLSTART");
    54     else if (type == wxEVT_SCI_DWELLEND)           name = 
_T(
"wxEVT_SCI_DWELLEND");
    55     else if (type == wxEVT_SCI_START_DRAG)         name = 
_T(
"wxEVT_SCI_START_DRAG");
    56     else if (type == wxEVT_SCI_DRAG_OVER)          name = 
_T(
"wxEVT_SCI_DRAG_OVER");
    57     else if (type == wxEVT_SCI_DO_DROP)            name = 
_T(
"wxEVT_SCI_DO_DROP");
    58     else if (type == wxEVT_SCI_ZOOM)               name = 
_T(
"wxEVT_SCI_ZOOM");
    59     else if (type == wxEVT_SCI_HOTSPOT_CLICK)      name = 
_T(
"wxEVT_SCI_HOTSPOT_CLICK");
    60     else if (type == wxEVT_SCI_HOTSPOT_DCLICK)     name = 
_T(
"wxEVT_SCI_HOTSPOT_DCLICK");
    61     else if (type == wxEVT_SCI_CALLTIP_CLICK)      name = 
_T(
"wxEVT_SCI_CALLTIP_CLICK");
    62     else if (type == wxEVT_SCI_AUTOCOMP_SELECTION) name = 
_T(
"wxEVT_SCI_AUTOCOMP_SELECTION");
    63     else if (type == wxEVT_SCI_INDICATOR_CLICK)    name = 
_T(
"wxEVT_SCI_INDICATOR_CLICK");
    64     else if (type == wxEVT_SCI_INDICATOR_RELEASE)  name = 
_T(
"wxEVT_SCI_INDICATOR_RELEASE");
    65     else name = 
_T(
"unknown wxEVT_SCI_EVENT");
    69 #endif // EDITOR_HOOK_PERFORMANCE_MEASURE    82         if (it->second == functor)
   118 #ifdef EDITOR_HOOK_PERFORMANCE_MEASURE   120 #endif // EDITOR_HOOK_PERFORMANCE_MEASURE   122             functor->
Call(editor, event);
   124 #ifdef EDITOR_HOOK_PERFORMANCE_MEASURE   128             const char *p = functor->GetTypeName();
   131             realname = abi::__cxa_demangle(p, 0, 0, &status);
   143             txt << GetScintillaEventName(type);
   145 #endif // EDITOR_HOOK_PERFORMANCE_MEASURE Provides static functions to add hooks to the editor modification operations. 
 
wxString F(const wxChar *msg,...)
sprintf-like function 
 
virtual void OnEditorHook(cbEditor *editor, wxScintillaEvent &event) const =0
When this is called, the smartIndent mechanism must get to work ;). 
 
static Manager * Get()
Use Manager::Get() to get a pointer to its instance Manager::Get() is guaranteed to never return an i...
 
cbSmartIndentEditorHookFunctor(cbSmartIndentPlugin *plugin)
ctor. 
 
DLLIMPORT bool HasRegisteredHooks()
Are there any hooks registered? 
 
cbSmartIndentPlugin * m_plugin
 
std::map< int, HookFunctorBase * > HookFunctorsMap
 
static wxString FromUTF8(const char *s)
 
LogManager * GetLogManager() const
 
const wxStringCharType * wx_str() const
 
void Call(cbEditor *editor, wxScintillaEvent &event) const override
Needs to be implemented by the plugin to act(smart indent) accordingly. 
 
Abstract base hook functor interface. 
 
virtual void Call(cbEditor *, wxScintillaEvent &) const =0
 
void DebugLog(const wxString &msg, Logger::level lv=Logger::info)
 
DLLIMPORT HookFunctorBase * UnregisterHook(int id, bool deleteHook=true)
Unregister a previously registered project loading/saving hook. 
 
static HookFunctorsMap s_HookFunctorsMap
 
DLLIMPORT void CallHooks(cbEditor *editor, wxScintillaEvent &event)
Call all registered hooks using the supplied parameters. 
 
DLLIMPORT int RegisterHook(HookFunctorBase *functor)
Register a project loading/saving hook.