~registry/codeblocks/trunk

« back to all changes in this revision

Viewing changes to src/plugins/contrib/wxSmithDateTimePicker/wxSmithDateTimePicker.cpp

  • Committer: mortenmacfly
  • Date: 2012-02-22 14:40:26 UTC
  • Revision ID: svn-v4:98b59c6a-2706-0410-b7d6-d2fa1a1880c9:trunk:7835
* merged wxSmith branch into trunk
* this brings tons of new wxSmith items, including KWIC, wxImagePanel, wxGridBagSizer and more
* based on work of the community, mainly cryogen
* for more information, see changelog of wxSmith branch
* also, re-factoring of contributed wxWidgets items for wxSmith
* PLEASE DO A CLEAN CHECKOUT AND RE-BUILD EVERYTHING FROM SCRATCH!

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#include <sdk.h> // Code::Blocks SDK
 
2
#include <configurationpanel.h>
 
3
#include "wxSmithDateTimePicker.h"
 
4
 
 
5
// Register the plugin with Code::Blocks.
 
6
// We are using an anonymous namespace so we don't litter the global one.
 
7
namespace
 
8
{
 
9
    PluginRegistrant<wxSmithDateTimePicker> reg(_T("wxSmithDateTimePicker"));
 
10
}
 
11
 
 
12
 
 
13
 
 
14
// constructor
 
15
wxSmithDateTimePicker::wxSmithDateTimePicker()
 
16
{
 
17
    // Make sure our resources are available.
 
18
    // In the generated boilerplate code we have no resources but when
 
19
    // we add some, it will be nice that this code is in place already ;)
 
20
    if(!Manager::LoadResource(_T("wxSmithDateTimePicker.zip")))
 
21
    {
 
22
        NotifyMissingFile(_T("wxSmithDateTimePicker.zip"));
 
23
    }
 
24
}
 
25
 
 
26
// destructor
 
27
wxSmithDateTimePicker::~wxSmithDateTimePicker()
 
28
{
 
29
}
 
30
 
 
31
void wxSmithDateTimePicker::OnAttach()
 
32
{
 
33
    // do whatever initialization you need for your plugin
 
34
    // NOTE: after this function, the inherited member variable
 
35
    // m_IsAttached will be TRUE...
 
36
    // You should check for it in other functions, because if it
 
37
    // is FALSE, it means that the application did *not* "load"
 
38
    // (see: does not need) this plugin...
 
39
}
 
40
 
 
41
void wxSmithDateTimePicker::OnRelease(bool appShutDown)
 
42
{
 
43
    // do de-initialization for your plugin
 
44
    // if appShutDown is true, the plugin is unloaded because Code::Blocks is being shut down,
 
45
    // which means you must not use any of the SDK Managers
 
46
    // NOTE: after this function, the inherited member variable
 
47
    // m_IsAttached will be FALSE...
 
48
}