glimmer-dsl-libui 0.11.7 → 0.11.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -0
- data/LICENSE.txt +1 -1
- data/README.md +83 -14
- data/VERSION +1 -1
- data/bin/girb +1 -1
- data/bin/girb_runner.rb +1 -1
- data/bin/glimmer +1 -1
- data/docs/examples/GLIMMER-DSL-LIBUI-ADVANCED-EXAMPLES.md +1 -1
- data/docs/examples/GLIMMER-DSL-LIBUI-BASIC-EXAMPLES.md +13 -689
- data/examples/basic_area.rb +3 -5
- data/examples/basic_area2.rb +6 -8
- data/examples/basic_area3.rb +5 -7
- data/examples/basic_area4.rb +8 -10
- data/examples/basic_table_button.rb +20 -22
- data/examples/basic_table_button2.rb +13 -15
- data/examples/basic_table_checkbox.rb +17 -19
- data/examples/basic_table_checkbox_text.rb +17 -19
- data/examples/basic_table_color.rb +8 -10
- data/examples/basic_table_color2.rb +7 -9
- data/examples/basic_table_color3.rb +7 -9
- data/examples/basic_table_image_text.rb +6 -8
- data/examples/basic_table_image_text2.rb +6 -8
- data/examples/basic_table_image_text3.rb +6 -8
- data/examples/date_time_picker.rb +17 -17
- data/examples/date_time_picker2.rb +5 -13
- data/examples/lazy_table.rb +8 -10
- data/examples/lazy_table2.rb +8 -10
- data/examples/lazy_table3.rb +8 -10
- data/examples/lazy_table4.rb +8 -10
- data/examples/simple_notepad.rb +1 -7
- data/examples/tetris/model/block.rb +1 -1
- data/examples/tetris/model/game.rb +1 -1
- data/examples/tetris/model/past_game.rb +1 -1
- data/examples/tetris/model/tetromino.rb +1 -1
- data/examples/tetris.rb +1 -1
- data/examples/tic_tac_toe/board.rb +1 -1
- data/examples/tic_tac_toe/cell.rb +1 -1
- data/glimmer-dsl-libui.gemspec +0 -0
- data/lib/glimmer/dsl/libui/bind_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/content_expression.rb +2 -1
- data/lib/glimmer/dsl/libui/control_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/custom_control_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/custom_shape_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/data_binding_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/dsl.rb +1 -1
- data/lib/glimmer/dsl/libui/file_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/listener_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/observe_expression.rb +2 -1
- data/lib/glimmer/dsl/libui/open_file_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/open_folder_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/operation_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/property_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/save_file_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/shape_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/shine_data_binding_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/string_expression.rb +1 -1
- data/lib/glimmer/dsl/libui/tab_item_expression.rb +1 -1
- data/lib/glimmer/fiddle_consumer.rb +1 -1
- data/lib/glimmer/libui/attributed_string.rb +1 -1
- data/lib/glimmer/libui/control_proxy/area_proxy/scrolling_area_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/area_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/box/horizontal_box_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/box/vertical_box_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/box.rb +1 -1
- data/lib/glimmer/libui/control_proxy/button_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/checkbox_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/color_button_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/background_color_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/button_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/checkbox_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/checkbox_text_color_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/checkbox_text_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/image_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/image_text_color_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/image_text_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/progress_bar_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/text_color_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column/text_column_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/column.rb +1 -1
- data/lib/glimmer/libui/control_proxy/combobox_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/date_time_picker_proxy/date_picker_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/date_time_picker_proxy/time_picker_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/date_time_picker_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/dual_column.rb +1 -1
- data/lib/glimmer/libui/control_proxy/editable_column.rb +1 -1
- data/lib/glimmer/libui/control_proxy/editable_combobox_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/enableable_column.rb +1 -1
- data/lib/glimmer/libui/control_proxy/entry_proxy/password_entry_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/entry_proxy/search_entry_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/entry_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/font_button_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/form_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/grid_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/group_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/image_part_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/image_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/label_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/matrix_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_item_proxy/about_menu_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_item_proxy/check_menu_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_item_proxy/preferences_menu_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_item_proxy/quit_menu_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_item_proxy/radio_menu_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_item_proxy/separator_menu_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/menu_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/message_box/msg_box_error_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/message_box/msg_box_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/message_box.rb +1 -1
- data/lib/glimmer/libui/control_proxy/multiline_entry_proxy/non_wrapping_multiline_entry_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/multiline_entry_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/open_type_features_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/open_type_tag_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/path_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/radio_buttons_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/slider_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/spinbox_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/tab_item_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/table_proxy.rb +6 -1
- data/lib/glimmer/libui/control_proxy/text_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy/transformable.rb +8 -3
- data/lib/glimmer/libui/control_proxy/triple_column.rb +1 -1
- data/lib/glimmer/libui/control_proxy/window_proxy.rb +1 -1
- data/lib/glimmer/libui/control_proxy.rb +3 -2
- data/lib/glimmer/libui/custom_control/code_area.rb +1 -1
- data/lib/glimmer/libui/custom_control/refined_table.rb +1 -1
- data/lib/glimmer/libui/custom_control.rb +1 -1
- data/lib/glimmer/libui/custom_shape.rb +1 -1
- data/lib/glimmer/libui/custom_window.rb +1 -1
- data/lib/glimmer/libui/data_bindable.rb +1 -1
- data/lib/glimmer/libui/parent.rb +1 -1
- data/lib/glimmer/libui/shape/arc.rb +1 -1
- data/lib/glimmer/libui/shape/bezier.rb +1 -1
- data/lib/glimmer/libui/shape/circle.rb +1 -1
- data/lib/glimmer/libui/shape/figure.rb +1 -1
- data/lib/glimmer/libui/shape/line.rb +1 -1
- data/lib/glimmer/libui/shape/polybezier.rb +1 -1
- data/lib/glimmer/libui/shape/polygon.rb +1 -1
- data/lib/glimmer/libui/shape/polyline.rb +1 -1
- data/lib/glimmer/libui/shape/rectangle.rb +1 -1
- data/lib/glimmer/libui/shape/square.rb +1 -1
- data/lib/glimmer/libui/shape.rb +3 -3
- data/lib/glimmer/libui.rb +1 -1
- data/lib/glimmer/rake_task/package.rb +1 -1
- data/lib/glimmer/rake_task/scaffold.rb +1 -1
- data/lib/glimmer/rake_task.rb +1 -1
- data/lib/glimmer-dsl-libui.rb +1 -1
- metadata +5 -5
@@ -1,4 +1,4 @@
|
|
1
|
-
# Copyright (c) 2021-
|
1
|
+
# Copyright (c) 2021-2024 Andy Maleh
|
2
2
|
#
|
3
3
|
# Permission is hereby granted, free of charge, to any person obtaining
|
4
4
|
# a copy of this software and associated documentation files (the
|
@@ -25,6 +25,7 @@ module Glimmer
|
|
25
25
|
module DSL
|
26
26
|
module Libui
|
27
27
|
class ContentExpression < Expression
|
28
|
+
# TODO rename to ContentDataBindingExpression given it is no longer a static_expression (and update in dsl.rb)
|
28
29
|
def can_interpret?(parent, keyword, *args, &block)
|
29
30
|
keyword == 'content' &&
|
30
31
|
block_given? &&
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# Copyright (c) 2021-
|
1
|
+
# Copyright (c) 2021-2024 Andy Maleh
|
2
2
|
#
|
3
3
|
# Permission is hereby granted, free of charge, to any person obtaining
|
4
4
|
# a copy of this software and associated documentation files (the
|
@@ -29,6 +29,7 @@ module Glimmer
|
|
29
29
|
class ObserveExpression < StaticExpression
|
30
30
|
include TopLevelExpression
|
31
31
|
include Glimmer::DSL::ObserveExpression
|
32
|
+
# TODO consider adding logic to auto-unregister observers created in this expression (unregister them elsewhere)
|
32
33
|
end
|
33
34
|
end
|
34
35
|
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# Copyright (c) 2021-
|
1
|
+
# Copyright (c) 2021-2024 Andy Maleh
|
2
2
|
#
|
3
3
|
# Permission is hereby granted, free of charge, to any person obtaining
|
4
4
|
# a copy of this software and associated documentation files (the
|
@@ -577,6 +577,11 @@ module Glimmer
|
|
577
577
|
end
|
578
578
|
|
579
579
|
def register_cell_rows_observer
|
580
|
+
# TODO update all the each_with_index calls below to work differently when value is an Enumerator
|
581
|
+
# Perhaps, call ::LibUI.table_model_row_inserted(model, row) not from here, yet from the place where
|
582
|
+
# we call `next` on the Enumerator to grab more elements
|
583
|
+
# There will need to be extra intelligence for figuring out when to delete instead of
|
584
|
+
# deleting a million rows when a change occurs
|
580
585
|
@cell_rows_observer = Glimmer::DataBinding::Observer.proc do |new_cell_rows|
|
581
586
|
if !@last_cell_rows.nil? # not initial load of table
|
582
587
|
if @cell_rows.size < @last_cell_rows.size
|