summaryrefslogtreecommitdiff
path: root/src/user/raleigh/w/vbox.cpp
diff options
context:
space:
mode:
authorBenji Dial <benji6283@gmail.com>2021-03-07 23:19:48 -0500
committerBenji Dial <benji6283@gmail.com>2021-03-07 23:19:48 -0500
commit1a5ece4f52ef17c7c868e95eb26e98137d5cab6f (patch)
tree2ab5c639d368d3ec497b464009f0401e71d433f1 /src/user/raleigh/w/vbox.cpp
parent348e1876d25320e6480f2795c9388b2bc080c743 (diff)
downloadportland-os-1a5ece4f52ef17c7c868e95eb26e98137d5cab6f.tar.gz
keyboard support in raleigh, word wrap and more in entry widget
Diffstat (limited to 'src/user/raleigh/w/vbox.cpp')
-rw-r--r--src/user/raleigh/w/vbox.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/user/raleigh/w/vbox.cpp b/src/user/raleigh/w/vbox.cpp
index 51b87ed..08c2539 100644
--- a/src/user/raleigh/w/vbox.cpp
+++ b/src/user/raleigh/w/vbox.cpp
@@ -27,16 +27,16 @@ namespace raleigh {
n->d.paint(pixbuf, pitch);
}
- bool vbox::try_handle_click(coord window_coords, enum mouse_packet::mouse_button click_type, bool up) {
+ void vbox::handle_click(coord window_coords, enum mouse_packet::mouse_button click_type, bool up) {
uint32_t h = window_offset.y;
dllist<widget &>::node *n = widgets.first;
while (h + n->d.size.y <= window_coords.y) {
h += n->d.size.y;
n = n->next;
}
- return (window_coords.x >= n->d.window_offset.x) &&
- (window_coords.x < n->d.window_offset.x + n->d.size.x) &&
- n->d.try_handle_click(window_coords, click_type, up);
+ if ((window_coords.x >= n->d.window_offset.x) &&
+ (window_coords.x < n->d.window_offset.x + n->d.size.x))
+ n->d.handle_click(window_coords, click_type, up);
}
void vbox::notify_has_opaque_parent(widget *parent) {
@@ -44,4 +44,8 @@ namespace raleigh {
for (dllist<widget &>::node *n = widgets.first; n; n = n->next)
n->d.notify_has_opaque_parent(parent);
}
+
+ void vbox::handle_key(struct key_packet kp) {};
+ void vbox::on_focus() {};
+ void vbox::on_unfocus() {};
} \ No newline at end of file