Develop and Download Open Source Software

Browse Subversion Repository

Contents of /view.rb

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2 - (show annotations) (download)
Tue Apr 3 18:03:39 2007 UTC (16 years, 11 months ago) by bluedwarf
File size: 1076 byte(s)
* Added Gtk+-2.0 support.
* Implement event handlers and action manager.

1
2 module Edmaru
3
4 #Abstract class to implement system specific view.
5 module View
6
7 #Construct the view instance.
8 #
9 #=== Warning
10 #This method *MUST* *NOT* be overrided in derived classes.
11 #
12 #=== Argument
13 #_event_manager_ :: An instance of Edmaru::EventManager to handler
14 #all events raised from this view.
15 #
16 #=== Return
17 #An initialized instance of View.
18 def initialize(event_manager)
19 @event_manager = event_manager
20 init
21 end
22
23 #The system specific initialization for this view.
24 #
25 #=== Warning
26 #This method *MUST* be overrided in derived classes.
27 def init
28 end
29
30 #Main loop to catch all events.
31 #
32 #=== Warning
33 #This method *SHOULD* be overrided in derived classes.
34 def main_loop
35 end
36
37 #Beep once.
38 #
39 #=== Warning
40 #This method *SHOULD* be overrided in derived classes.
41 def beep
42 false
43 end
44
45 #Terminate this view instance.
46 #
47 #=== Warning
48 #This method *SHOULD* be overrided in derived classes.
49 def terminate
50 end
51 end
52 end

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26