diff options
author | nyamatongwe <unknown> | 2009-05-14 12:10:06 +0000 |
---|---|---|
committer | nyamatongwe <unknown> | 2009-05-14 12:10:06 +0000 |
commit | 805e109be2f52c0ea446511fc33efb3746a3bc18 (patch) | |
tree | 3b57cf166d494a0dba47befcea94deba3da0fbda /cocoa/ScintillaListBox.h | |
parent | 8e12be32e9d14363f1e2f0fe6fc305b68a64ceb5 (diff) | |
download | scintilla-mirror-805e109be2f52c0ea446511fc33efb3746a3bc18.tar.gz |
First upload of Cocoa platform from Mike Lischke at Sun.
Diffstat (limited to 'cocoa/ScintillaListBox.h')
-rw-r--r-- | cocoa/ScintillaListBox.h | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/cocoa/ScintillaListBox.h b/cocoa/ScintillaListBox.h new file mode 100644 index 000000000..c42576e6d --- /dev/null +++ b/cocoa/ScintillaListBox.h @@ -0,0 +1,64 @@ + +/* + * ScintillaMacOSX.h + * tutorial + * + * Created by Evan Jones on Sun Sep 01 2002. + * + */ + +#ifndef SCINTILLA_LISTBOX_H +#define SCINTILLA_LISTBOX_H + +#include "TView.h" + +#include <stdlib.h> +#include <string.h> +#include <stdio.h> +#include <ctype.h> +#include <time.h> + +#include "Platform.h" +#include "Scintilla.h" + +static const OSType scintillaListBoxType = 'sclb'; + +namespace Scintilla { + +class ScintillaListBox : public TView +{ +public: + // Private so ScintillaListBox objects can not be copied + ScintillaListBox(const ScintillaListBox &) : TView( NULL ) {} + ScintillaListBox &operator=(const ScintillaListBox &) { return * this; } + ~ScintillaListBox() {}; + +public: + /** This is the class ID that we've assigned to Scintilla. */ + static const CFStringRef kScintillaListBoxClassID; + static const ControlKind kScintillaListBoxKind; + + ScintillaListBox( void* windowid ); + + /** Returns the HIView object kind, needed to subclass TView. */ + virtual ControlKind GetKind() { return kScintillaListBoxKind; } + +private: + + virtual ControlPartCode HitTest( const HIPoint& where ); + virtual void Draw( RgnHandle rgn, CGContextRef gc ); + virtual OSStatus MouseDown( HIPoint& location, UInt32 modifiers, EventMouseButton button, UInt32 clickCount ); + virtual OSStatus MouseUp( HIPoint& location, UInt32 modifiers, EventMouseButton button, UInt32 clickCount ); + +public: + static HIViewRef Create(); +private: + static OSStatus Construct( HIViewRef inControl, TView** outView ); + +}; + + +} + + +#endif |