Mercurial > projects > doodle
comparison doodle/tk/screen_model.d @ 88:100dd23c7bdf
Ch ch ch changes:
* Handle SIGINT like a geek for now
* GtkD Context has no destructor and hence it would seem, a memory leak
* No more gtk_* C-function invocations
* Configured my GtkD patches
* (Comments)
author | David Bryant <bagnose@gmail.com> |
---|---|
date | Wed, 18 Aug 2010 23:51:43 +0930 |
parents | d92b9f04b1e8 |
children | 42766e14534e |
comparison
equal
deleted
inserted
replaced
87:c825e6db57c1 | 88:100dd23c7bdf |
---|---|
6 | 6 |
7 private { | 7 private { |
8 import doodle.core.misc; | 8 import doodle.core.misc; |
9 } | 9 } |
10 | 10 |
11 /* | |
12 interface IScreenModelObserver { | |
13 void screenDamaged(in Rectangle screenDamage); | |
14 void cursorChanged(in Cursor cursor); | |
15 } | |
16 */ | |
17 | |
11 // This class manages the relationship between screen space and model space. | 18 // This class manages the relationship between screen space and model space. |
12 // Screen is defined as the current window/viewport into the model | 19 // Screen is defined as the current window/viewport into the model |
13 // It provides convenient high-level operations. | 20 // It provides convenient high-level operations. |
14 // | 21 // |
15 // x and y run right and up respectively for screen and model space | 22 // x and y run right and up respectively for screen and model space |
16 | 23 |
17 class ScreenModel { | 24 class ScreenModel { |
25 /* | |
26 void damageModel | |
27 */ | |
28 | |
29 | |
18 this(in double zoom, in Rectangle canvasBoundsModel, in Rectangle viewBoundsScreen) { | 30 this(in double zoom, in Rectangle canvasBoundsModel, in Rectangle viewBoundsScreen) { |
19 _zoom = zoom; | 31 _zoom = zoom; |
20 _viewBoundsScreen = viewBoundsScreen; | 32 _viewBoundsScreen = viewBoundsScreen; |
21 _canvasBoundsModel = canvasBoundsModel; | 33 _canvasBoundsModel = canvasBoundsModel; |
22 | 34 |