lib/wx/shapes/connection_point.rb in wxruby3-shapes-0.9.0.pre.beta.3 vs lib/wx/shapes/connection_point.rb in wxruby3-shapes-0.9.5

- old
+ new

@@ -5,11 +5,11 @@ module Wx::SF class ConnectionPoint - include Wx::SF::Serializable + include FIRM::Serializable property :type property :ortho_direction property :relative_position @@ -71,17 +71,26 @@ @ortho_dir = DEFAULT::ORTHODIR @mouse_over = false end end + attr_accessor :id + # Get connection point type. # @return [CPTYPE] Connection point type def get_type @type end alias :type :get_type + # Set connection point type. + # @param [CPTYPE] type + def set_type(type) + @type = type + end + alias :type= :set_type + # Set direction of orthogonal line's connection. # @param [CPORTHODIR] dir Required direction # @see CPORTHODIR def set_ortho_direction(dir) @ortho_dir = dir @@ -209,14 +218,9 @@ end end end private - - # For deserialization - def set_type(type) - @type = type - end # Event handler called when the mouse pointer is moving above shape canvas. # @param [Wx::Point] pos Current mouse position def _on_mouse_move(pos) if contains?(pos)