| jcomponent.h | | jcomponent.h | |
| | | | |
| skipping to change at line 131 | | skipping to change at line 131 | |
| class Component : public virtual jcommon::Object{ | | class Component : public virtual jcommon::Object{ | |
| | | | |
| friend class Container; | | friend class Container; | |
| friend class Frame; | | friend class Frame; | |
| | | | |
| protected: | | protected: | |
| jthread::Mutex _component_mutex; | | jthread::Mutex _component_mutex; | |
| | | | |
| std::vector<FocusListener *> _focus_listeners; | | std::vector<FocusListener *> _focus_listeners; | |
| std::vector<ComponentListener *> _component_listeners; | | std::vector<ComponentListener *> _component_listeners; | |
|
| Component *_left, | | | |
| *_right, | | | |
| *_up, | | | |
| *_down; | | | |
| jgui::Container *_parent; | | jgui::Container *_parent; | |
|
| | | Component *_left, | |
| | | *_right, | |
| | | *_up, | |
| | | *_down; | |
| jgui::Font *_font; | | jgui::Font *_font; | |
|
| jpoint_t _location; | | std::string _name; | |
| | | jpoint_t _location, | |
| | | _scroll_location; | |
| jsize_t _size, | | jsize_t _size, | |
|
| _preferred_size, | | _preferred_size, | |
| _minimum_size, | | _minimum_size, | |
| _maximum_size; | | _maximum_size; | |
| Color _bgcolor, | | Color _bgcolor, | |
|
| _fgcolor, | | _fgcolor, | |
| _focus_bgcolor, | | _focus_bgcolor, | |
| _focus_fgcolor, | | _focus_fgcolor, | |
| _border_color, | | _border_color, | |
| _focus_border_color; | | _focus_border_color, | |
| | | _scrollbar_color, | |
| | | _disabled_bgcolor, | |
| | | _disabled_fgcolor, | |
| | | _disabled_border_color; | |
| jcomponent_alignment_t _alignment_x, | | jcomponent_alignment_t _alignment_x, | |
|
|
_alignment_y; | | _alignment_y; | |
| jcomponent_orientation_t _orientation; | | jcomponent_orientation_t _orientation; | |
| jcomponent_border_t _border; | | jcomponent_border_t _border; | |
| int _gradient_level, | | int _gradient_level, | |
|
| _vertical_gap, | | _vertical_gap, | |
| _horizontal_gap, | | _horizontal_gap, | |
| _border_size; | | _border_size, | |
| | | _scroll_size, | |
| | | _scroll_gap, | |
| | | _scroll_minor_increment, | |
| | | _scroll_major_increment; | |
| | | int _relative_mouse_x, | |
| | | _relative_mouse_y, | |
| | | _relative_mouse_w, | |
| | | _relative_mouse_h, | |
| | | _internal_state; | |
| bool _has_focus, | | bool _has_focus, | |
|
| _is_visible, | | _is_visible, | |
| _ignore_repaint, | | _is_cyclic_focus, | |
| _background_visible, | | _is_navigation_enabled, | |
| _is_focusable, | | _is_ignore_repaint, | |
| _enabled, | | _is_background_visible, | |
| _theme_enabled, | | _is_focusable, | |
| _is_opaque, | | _is_enabled, | |
| _is_valid; | | _is_theme_enabled, | |
| | | _is_opaque, | |
| | | _is_valid, | |
| | | _is_scrollable_x, | |
| | | _is_scrollable_y, | |
| | | _is_scroll_visible, | |
| | | _is_smooth_scroll; | |
| | | | |
| protected: | | protected: | |
|
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void GetInternalComponents(Container *parent, std::v | |
| | | ector<Component *> *components); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void FindNextComponentFocus(jregion_t rect, Componen | |
| | | t **left, Component **right, Component **up, Component **down); | |
| | | | |
| | | /** | |
| | | * \brief Makes sure the component is visible in the scroll | |
| | | if this container is scrollable. | |
| | | * | |
| | | * @param x | |
| | | * @param y | |
| | | * @param width | |
| | | * @param height | |
| | | * @param coordinateSpace the component according to whose c | |
| | | oordinates rect is defined. Rect's | |
| | | * x/y are relative to that component (they are | |
| | | not absolute). | |
| | | * | |
| | | */ | |
| | | virtual void ScrollToVisibleArea(int x, int y, int width, in | |
| | | t height, Component *coordinateSpace); | |
| | | | |
| public: | | public: | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| Component(int x = 0, int y = 0, int width = 0, int height =
0); | | Component(int x = 0, int y = 0, int width = 0, int height =
0); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual ~Component(); | | virtual ~Component(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetName(std::string name); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual std::string GetName(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual Container * GetParent(); | | virtual Container * GetParent(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Container * GetTopLevelAncestor(); | | virtual Container * GetTopLevelAncestor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 245 | | skipping to change at line 302 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual jcomponent_orientation_t GetComponentOrientation(); | | virtual jcomponent_orientation_t GetComponentOrientation(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual bool IsScrollableX(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool IsScrollableY(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollableX(bool scrollable); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollableY(bool scrollable); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollable(bool scrollable); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetSmoothScrolling(bool smooth); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool IsCyclicFocus(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetCyclicFocus(bool b); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool IsSmoothScrolling(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool IsScrollable(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool IsScrollVisible(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual jpoint_t GetAbsoluteLocation(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual jpoint_t GetScrollLocation(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual jsize_t GetScrollDimension(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual jregion_t GetVisibleBounds(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollX(int x); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollY(int y); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollLocation(jpoint_t t); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual int GetScrollSize(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollSize(int size); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual int GetScrollGap(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetScrollGap(int gap); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual int GetMinorScrollIncrement(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual int GetMajorScrollIncrement(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetMinorScrollIncrement(int increment); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetMajorScrollIncrement(int increment); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetThemeEnabled(bool b); | | virtual void SetThemeEnabled(bool b); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual bool IsThemeEnabled(); | | virtual bool IsThemeEnabled(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 329 | | skipping to change at line 542 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetParent(Container *parent); | | virtual void SetParent(Container *parent); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual bool IsBackgroundVisible(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetBackgroundVisible(bool b); | | virtual void SetBackgroundVisible(bool b); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual bool IsEnabled(); | | virtual bool IsEnabled(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetEnabled(bool b); | | virtual void SetEnabled(bool b); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetNavigation(Component *left, Component *right
, Component *up, Component *down); | | virtual void SetLeftComponent(Component *left); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Component * GetLeftComponent(); | | virtual void SetRightComponent(Component *right); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Component * GetRightComponent(); | | virtual void SetUpComponent(Component *up); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Component * GetUpComponent(); | | virtual void SetDownComponent(Component *down); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Component * GetDownComponent(); | | virtual void SetNavigationEnabled(bool b); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool IsNavigationEnabled(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetNextComponentFocus(Component *left, Componen | |
| | | t *right, Component *up, Component *down); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Component * GetNextFocusLeft(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Component * GetNextFocusRight(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Component * GetNextFocusUp(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Component * GetNextFocusDown(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual bool ProcessEvent(KeyEvent *event); | | virtual bool ProcessEvent(KeyEvent *event); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
| skipping to change at line 434 | | skipping to change at line 689 | |
| */ | | */ | |
| virtual void SetBorderSize(int size); | | virtual void SetBorderSize(int size); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual int GetBorderSize(); | | virtual int GetBorderSize(); | |
| | | | |
| /** | | /** | |
|
| | | * \brief Verify if the second component contains the first | |
| | | one; | |
| | | * | |
| | | */ | |
| | | virtual bool Contains(Component *c1, Component *c2); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool Contains(Component *c, int x, int y, int w, int | |
| | | h); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool Contains(int x1, int y1, int w1, int h1, int x2 | |
| | | , int y2, int w2, int h2); | |
| | | | |
| | | /** | |
| | | * \brief Verify if the second component intersects the firs | |
| | | t one; | |
| | | * | |
| | | */ | |
| | | virtual bool Intersects(Component *c1, Component *c2); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool Intersects(Component *c, int x, int y, int w, i | |
| | | nt h); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual bool Intersects(int x1, int y1, int w1, int h1, int | |
| | | x2, int y2, int w2, int h2); | |
| | | | |
| | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetMinimumSize(jsize_t size); | | virtual void SetMinimumSize(jsize_t size); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetMaximumSize(jsize_t size); | | virtual void SetMaximumSize(jsize_t size); | |
| | | | |
| skipping to change at line 539 | | skipping to change at line 830 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual int GetY(); | | virtual int GetY(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual int GetAbsoluteX(); | | | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual int GetAbsoluteY(); | | | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual int GetWidth(); | | virtual int GetWidth(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual int GetHeight(); | | virtual int GetHeight(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 665 | | skipping to change at line 944 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetBorderFocusColor(int red, int green, int blu
e, int alpha); | | virtual void SetBorderFocusColor(int red, int green, int blu
e, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetScrollbarColor(int red, int green, int blue, | |
| | | int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetDisabledBackgroundColor(int red, int green, | |
| | | int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetDisabledForegroundColor(int red, int green, | |
| | | int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetDisabledBorderColor(int red, int green, int | |
| | | blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetBackgroundColor(const Color &color); | | virtual void SetBackgroundColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetForegroundColor(const Color &color); | | virtual void SetForegroundColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 701 | | skipping to change at line 1004 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetBorderFocusColor(const Color &color); | | virtual void SetBorderFocusColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetScrollbarColor(const Color &color); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetDisabledBackgroundColor(const Color &color); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetDisabledForegroundColor(const Color &color); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetDisabledBorderColor(const Color &color); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual Color & GetBackgroundColor(); | | virtual Color & GetBackgroundColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetForegroundColor(); | | virtual Color & GetForegroundColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 737 | | skipping to change at line 1064 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetBorderFocusColor(); | | virtual Color & GetBorderFocusColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual Color & GetScrollbarColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Color & GetDisabledBackgroundColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Color & GetDisabledForegroundColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Color & GetDisabledBorderColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetFocusable(bool b); | | virtual void SetFocusable(bool b); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual bool IsFocusable(); | | virtual bool IsFocusable(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 761 | | skipping to change at line 1112 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void Paint(Graphics *g); | | virtual void Paint(Graphics *g); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void PaintBorderBackground(Graphics *g); | | virtual void PaintBackground(Graphics *g); | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void PaintBorderEdges(Graphics *g); | | virtual void PaintBorders(Graphics *g); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void Repaint(bool all = false); | | virtual void PaintScrollbars(Graphics *g); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void Repaint(Component *cmp = NULL); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void RegisterFocusListener(FocusListener *listener); | | virtual void RegisterFocusListener(FocusListener *listener); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
End of changes. 25 change blocks. |
| 45 lines changed or deleted | | 419 lines changed or added | |
|
| jcontainer.h | | jcontainer.h | |
| | | | |
| skipping to change at line 57 | | skipping to change at line 57 | |
| class Container : public jgui::Component{ | | class Container : public jgui::Component{ | |
| | | | |
| friend class Component; | | friend class Component; | |
| | | | |
| protected: | | protected: | |
| jthread::Mutex _container_mutex; | | jthread::Mutex _container_mutex; | |
| | | | |
| std::vector<ContainerListener *> _container_listeners; | | std::vector<ContainerListener *> _container_listeners; | |
| std::vector<Component *> _components; | | std::vector<Component *> _components; | |
| Component *_focus; | | Component *_focus; | |
|
| jgui::Layout *_layout; | | Layout *_layout; | |
| | | jsize_t _scroll_dimension; | |
| jinsets_t _insets; | | jinsets_t _insets; | |
| jsize_t _scale; | | jsize_t _scale; | |
|
| jpoint_t _scroll; | | | |
| bool _optimized_paint; | | bool _optimized_paint; | |
| | | | |
| protected: | | protected: | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void RequestComponentFocus(jgui::Component *c); | | virtual void RequestComponentFocus(jgui::Component *c); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual Component * GetTargetComponent(Container *target, in | |
| | | t x, int y, int *dx = NULL, int *dy = NULL); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void ReleaseComponentFocus(jgui::Component *c); | | virtual void ReleaseComponentFocus(jgui::Component *c); | |
| | | | |
|
| | | /** | |
| | | * \brief This method scrolls the Container if Scrollable to | |
| | | wards the given Component based on the given direction. | |
| | | * | |
| | | * \param direction is the direction of the navigation | |
| | | * \param next the Component to move the scroll towards | |
| | | * | |
| | | * \return true if next Component is now visible | |
| | | */ | |
| | | virtual bool MoveScrollTowards(Component *next, jkeyevent_sy | |
| | | mbol_t symbol); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void UpdateScrollDimension(); | |
| | | | |
| public: | | public: | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| Container(int x = 0, int y = 0, int width = 0, int height =
0, int scale_width = DEFAULT_SCALE_WIDTH, int scale_height = DEFAULT_SCALE_
HEIGHT); | | Container(int x = 0, int y = 0, int width = 0, int height =
0, int scale_width = DEFAULT_SCALE_WIDTH, int scale_height = DEFAULT_SCALE_
HEIGHT); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
| skipping to change at line 135 | | skipping to change at line 157 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual jinsets_t GetInsets(); | | virtual jinsets_t GetInsets(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetSize(int width, int height); | | | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void SetInsets(jinsets_t insets); | | virtual void SetInsets(jinsets_t insets); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetInsets(int left, int top, int right, int bot
tom); | | virtual void SetInsets(int left, int top, int right, int bot
tom); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 195 | | skipping to change at line 211 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void RemoveAll(); | | virtual void RemoveAll(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual int GetComponentCount(); | | virtual bool Contains(Component *cmp); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual std::vector<Component *> & GetComponents(); | | virtual int GetComponentCount(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual bool Intersect(Component *c1, Component *c2); | | virtual std::vector<Component *> & GetComponents(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual bool Intersect(Component *c1, int x, int y, int w, i
nt h); | | virtual void InvalidateAll(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void InvalidateAll(); | | virtual void RevalidateAll(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void RevalidateAll(); | | virtual void PaintGlassPane(Graphics *g); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void Paint(Graphics *g); | | virtual void Paint(Graphics *g); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void Repaint(bool all = true); | | virtual void Repaint(Component *cmp = NULL); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void Repaint(int x, int y, int width, int height); | | virtual jsize_t GetScrollDimension(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void Repaint(Component *c); | | virtual bool ProcessEvent(KeyEvent *event); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Component * GetTargetComponent(Container *target, in
t x, int y, int *dx = NULL, int *dy = NULL); | | virtual bool ProcessEvent(MouseEvent *event); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual jgui::Component * GetFocusOwner(); | | virtual jgui::Component * GetFocusOwner(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
End of changes. 15 change blocks. |
| 18 lines changed or deleted | | 37 lines changed or added | |
|
| jdatagramsocket.h | | jdatagramsocket.h | |
| | | | |
| skipping to change at line 24 | | skipping to change at line 24 | |
| *
* | | *
* | |
| * You should have received a copy of the GNU General Public License
* | | * You should have received a copy of the GNU General Public License
* | |
| * along with this program; if not, write to the
* | | * along with this program; if not, write to the
* | |
| * Free Software Foundation, Inc.,
* | | * Free Software Foundation, Inc.,
* | |
| * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | |
| **************************************************************************
*/ | | **************************************************************************
*/ | |
| #ifndef J_DATAGRAMSOCKET_H | | #ifndef J_DATAGRAMSOCKET_H | |
| #define J_DATAGRAMSOCKET_H | | #define J_DATAGRAMSOCKET_H | |
| | | | |
| #include "jinetaddress.h" | | #include "jinetaddress.h" | |
|
| #include "jsocketoption.h" | | #include "jsocketoptions.h" | |
| #include "jsocketinputstream.h" | | #include "jsocketinputstream.h" | |
| #include "jsocketoutputstream.h" | | #include "jsocketoutputstream.h" | |
| #include "jconnection.h" | | #include "jconnection.h" | |
| | | | |
| #include <string> | | #include <string> | |
| | | | |
| #ifdef _WIN32 | | #ifdef _WIN32 | |
| #include <windows.h> | | #include <windows.h> | |
| #else | | #else | |
| #include <sys/socket.h> | | #include <sys/socket.h> | |
| | | | |
| skipping to change at line 198 | | skipping to change at line 198 | |
| */ | | */ | |
| virtual int64_t GetSentBytes(); | | virtual int64_t GetSentBytes(); | |
| | | | |
| /** | | /** | |
| * \brief Get received bytes from a source. | | * \brief Get received bytes from a source. | |
| * | | * | |
| */ | | */ | |
| virtual int64_t GetReadedBytes(); | | virtual int64_t GetReadedBytes(); | |
| | | | |
| /** | | /** | |
|
| * \brief Get a object SocketOption. | | * \brief Get a object SocketOptions. | |
| * | | * | |
| */ | | */ | |
|
| SocketOption * GetSocketOption(); | | SocketOptions * GetSocketOptions(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual std::string what(); | | virtual std::string what(); | |
| | | | |
| }; | | }; | |
| | | | |
| } | | } | |
| | | | |
End of changes. 3 change blocks. |
| 3 lines changed or deleted | | 3 lines changed or added | |
|
| jdatagramsocket6.h | | jdatagramsocket6.h | |
| | | | |
| skipping to change at line 23 | | skipping to change at line 23 | |
| * GNU General Public License for more details.
* | | * GNU General Public License for more details.
* | |
| *
* | | *
* | |
| * You should have received a copy of the GNU General Public License
* | | * You should have received a copy of the GNU General Public License
* | |
| * along with this program; if not, write to the
* | | * along with this program; if not, write to the
* | |
| * Free Software Foundation, Inc.,
* | | * Free Software Foundation, Inc.,
* | |
| * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | |
| **************************************************************************
*/ | | **************************************************************************
*/ | |
| #ifndef J_DATAGRAMSOCKET6_H | | #ifndef J_DATAGRAMSOCKET6_H | |
| #define J_DATAGRAMSOCKET6_H | | #define J_DATAGRAMSOCKET6_H | |
| | | | |
|
| #include "jinetaddress.h" | | #include "jinetaddress6.h" | |
| #include "jsocketoption.h" | | #include "jsocketoptions.h" | |
| #include "jsocketinputstream.h" | | #include "jsocketinputstream.h" | |
| #include "jsocketoutputstream.h" | | #include "jsocketoutputstream.h" | |
| #include "jconnection.h" | | #include "jconnection.h" | |
| | | | |
| #include <string> | | #include <string> | |
| | | | |
| #ifdef _WIN32 | | #ifdef _WIN32 | |
| #include <windows.h> | | #include <windows.h> | |
| #else | | #else | |
| #include <sys/socket.h> | | #include <sys/socket.h> | |
| | | | |
| skipping to change at line 60 | | skipping to change at line 60 | |
| /** \brief Use to bind the socket in a free port. */ | | /** \brief Use to bind the socket in a free port. */ | |
| static int _used_port; | | static int _used_port; | |
| | | | |
| /** \brief Socket handler. */ | | /** \brief Socket handler. */ | |
| jsocket_t _fd; | | jsocket_t _fd; | |
| /** \brief Local socket. */ | | /** \brief Local socket. */ | |
| struct sockaddr_in6 _lsock; | | struct sockaddr_in6 _lsock; | |
| /** \brief Server socket UDP. */ | | /** \brief Server socket UDP. */ | |
| struct sockaddr_in6 _server_sock; | | struct sockaddr_in6 _server_sock; | |
| /** \brief Local inetaddress. */ | | /** \brief Local inetaddress. */ | |
|
| InetAddress *_local; | | InetAddress6 *_local; | |
| /** \brief Remote inetaddress. */ | | /** \brief Remote inetaddress. */ | |
| InetAddress *_address; | | InetAddress *_address; | |
| /** \brief Input stream. */ | | /** \brief Input stream. */ | |
| SocketInputStream *_is; | | SocketInputStream *_is; | |
| /** \brief Output stream. */ | | /** \brief Output stream. */ | |
| SocketOutputStream *_os; | | SocketOutputStream *_os; | |
| /** \brief Bytes sent. */ | | /** \brief Bytes sent. */ | |
| int64_t _sent_bytes; | | int64_t _sent_bytes; | |
| /** \brief Bytes received. */ | | /** \brief Bytes received. */ | |
| int64_t _receive_bytes; | | int64_t _receive_bytes; | |
| | | | |
| skipping to change at line 198 | | skipping to change at line 198 | |
| */ | | */ | |
| virtual int64_t GetSentBytes(); | | virtual int64_t GetSentBytes(); | |
| | | | |
| /** | | /** | |
| * \brief Get received bytes from a source. | | * \brief Get received bytes from a source. | |
| * | | * | |
| */ | | */ | |
| virtual int64_t GetReadedBytes(); | | virtual int64_t GetReadedBytes(); | |
| | | | |
| /** | | /** | |
|
| * \brief Get a object SocketOption. | | * \brief Get a object SocketOptions. | |
| * | | * | |
| */ | | */ | |
|
| SocketOption * GetSocketOption(); | | SocketOptions * GetSocketOptions(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual std::string what(); | | virtual std::string what(); | |
| | | | |
| }; | | }; | |
| | | | |
| } | | } | |
| | | | |
End of changes. 4 change blocks. |
| 5 lines changed or deleted | | 5 lines changed or added | |
|
| jgraphics.h | | jgraphics.h | |
| | | | |
| skipping to change at line 194 | | skipping to change at line 194 | |
| * \brief | | * \brief | |
| * | | * | |
| * \author Jeff Ferr | | * \author Jeff Ferr | |
| */ | | */ | |
| class Graphics : public virtual jcommon::Object{ | | class Graphics : public virtual jcommon::Object{ | |
| | | | |
| friend class Window; | | friend class Window; | |
| friend class Image; | | friend class Image; | |
| | | | |
| protected: | | protected: | |
|
| jthread::Mutex graphics_mutex; | | jthread::Mutex _graphics_mutex; | |
| | | | |
|
| struct jregion_t _clip; | | struct jregion_t _clip, | |
| | | | |
| | | _internal_clip; | |
| struct jpoint_t _translate, | | struct jpoint_t _translate, | |
|
_translate_image; | |
_translate_image; | |
| struct jsize_t _screen; | | struct jsize_t _screen; | |
| struct jsize_t _scale; | | struct jsize_t _scale; | |
| jline_join_t _line_join; | | jline_join_t _line_join; | |
| jline_style_t _line_style; | | jline_style_t _line_style; | |
| jdrawing_flags_t _draw_flags; | | jdrawing_flags_t _draw_flags; | |
| jblitting_flags_t _blit_flags; | | jblitting_flags_t _blit_flags; | |
| jporterduff_flags_t _porterduff_flags; | | jporterduff_flags_t _porterduff_flags; | |
| Font *_font; | | Font *_font; | |
| Color _color; | | Color _color; | |
| double _radians; | | double _radians; | |
| int _line_width; | | int _line_width; | |
| bool _is_premultiply, | | bool _is_premultiply, | |
| _antialias_enabled; | | _antialias_enabled; | |
| | | | |
| private: | | private: | |
| #ifdef DIRECTFB_UI | | #ifdef DIRECTFB_UI | |
| IDirectFBSurface *surface; | | IDirectFBSurface *surface; | |
| | | | |
|
| struct edge_t { | | | |
| struct edge_t *next; | | | |
| | | | |
| int yUpper; | | | |
| double xIntersect; | | | |
| double dxPerScan; | | | |
| }; | | | |
| | | | |
| int CalculateGradientChannel(int schannel, int dchannel, int
distance, int offset); | | int CalculateGradientChannel(int schannel, int dchannel, int
distance, int offset); | |
| void UpdateGradientColor(Color &scolor, Color &dcolor, int d
istance, int offset); | | void UpdateGradientColor(Color &scolor, Color &dcolor, int d
istance, int offset); | |
| | | | |
|
| void MakeEdgeRec(struct jpoint_t lower, struct jpoint_t uppe | | void FillPolygon0(jgui::jpoint_t *points, int npoints, int x | |
| r, int yComp, edge_t *edge, edge_t *edges[]); | | 1p, int y1p, int x2p, int y2p); | |
| void FillScan(int scan, edge_t *active); | | | |
| int YNext(int k, int cnt, jpoint_t pts[]); | | | |
| void BuildEdgeList(int cnt, jpoint_t pts[], edge_t *edges[]) | | | |
| ; | | | |
| void InsertEdge(edge_t *list, edge_t *edge); | | | |
| void UpdateActiveList(int scan, edge_t *active); | | | |
| void FillPolygon0(int n, int ppts[]); | | | |
| | | | |
| double EvaluateBezier0(double *data, int ndata, double t); | | double EvaluateBezier0(double *data, int ndata, double t); | |
| | | | |
| void DrawRectangle0(int xp, int yp, int wp, int hp, int dx,
int dy, jline_join_t join, int size); | | void DrawRectangle0(int xp, int yp, int wp, int hp, int dx,
int dy, jline_join_t join, int size); | |
| void DrawEllipse0(int xcp, int ycp, int rxp, int ryp, int si
ze); | | void DrawEllipse0(int xcp, int ycp, int rxp, int ryp, int si
ze); | |
| void DrawArc0(int xcp, int ycp, int rxp, int ryp, double arc
0, double arc1, int size, int quadrant); | | void DrawArc0(int xcp, int ycp, int rxp, int ryp, double arc
0, double arc1, int size, int quadrant); | |
| void DrawPie0(int xcp, int ycp, int rxp, int ryp, double arc
0, double arc1, int size); | | void DrawPie0(int xcp, int ycp, int rxp, int ryp, double arc
0, double arc1, int size); | |
| void DrawChord0(int xcp, int ycp, int rxp, int ryp, double a
rc0, double arc1, int size); | | void DrawChord0(int xcp, int ycp, int rxp, int ryp, double a
rc0, double arc1, int size); | |
| | | | |
| void AntiAlias0(DFBRegion *lines, int size); | | void AntiAlias0(DFBRegion *lines, int size); | |
| | | | |
| skipping to change at line 765 | | skipping to change at line 752 | |
| * | | * | |
| */ | | */ | |
| virtual void SetRGB(uint32_t *rgb, int xp, int yp, int wp, i
nt hp, int scanline); | | virtual void SetRGB(uint32_t *rgb, int xp, int yp, int wp, i
nt hp, int scanline); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void Reset(); | | virtual void Reset(); | |
| | | | |
|
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void Lock(); | | | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void Unlock(); | | | |
| | | | |
| }; | | }; | |
| | | | |
| } | | } | |
| | | | |
| #endif | | #endif | |
| | | | |
End of changes. 5 change blocks. |
| 31 lines changed or deleted | | 6 lines changed or added | |
|
| jitemcomponent.h | | jitemcomponent.h | |
| | | | |
| skipping to change at line 60 | | skipping to change at line 60 | |
| | | | |
| private: | | private: | |
| std::vector<Item *> _childs; | | std::vector<Item *> _childs; | |
| Image *_prefetch; | | Image *_prefetch; | |
| std::string _value, | | std::string _value, | |
| _image; | | _image; | |
| jmenuitem_type_t _type; | | jmenuitem_type_t _type; | |
| jhorizontal_align_t _halign; | | jhorizontal_align_t _halign; | |
| jvertical_align_t _valign; | | jvertical_align_t _valign; | |
| bool _is_checked, | | bool _is_checked, | |
|
| _is_visible, | | _is_visible, | |
| _enabled; | | _is_enabled; | |
| | | | |
| public: | | public: | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| Item(); | | Item(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 134 | | skipping to change at line 134 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetEnabled(bool b); | | virtual void SetEnabled(bool b); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual bool GetEnabled(); | | virtual bool IsEnabled(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetVisible(bool b); | | virtual void SetVisible(bool b); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
| skipping to change at line 228 | | skipping to change at line 228 | |
| * | | * | |
| * \author Jeff Ferr | | * \author Jeff Ferr | |
| */ | | */ | |
| class ItemComponent : public jgui::Component{ | | class ItemComponent : public jgui::Component{ | |
| | | | |
| protected: | | protected: | |
| std::vector<SelectListener *> _select_listeners; | | std::vector<SelectListener *> _select_listeners; | |
| std::vector<Item *> _items, | | std::vector<Item *> _items, | |
| _internal; | | _internal; | |
| Color _item_color, | | Color _item_color, | |
|
| _focus_item_color, | | _item_fgcolor, | |
| _selected_item_color, | | _selected_item_color, | |
| _selected_item_fgcolor, | | _selected_item_fgcolor, | |
| _item_fgcolor, | | _focus_item_color, | |
| _focus_item_fgcolor; | | _focus_item_fgcolor, | |
| | | _disabled_item_color, | |
| | | _disabled_item_fgcolor; | |
| std::string _text; | | std::string _text; | |
| int _index; | | int _index; | |
| bool _loop; | | bool _loop; | |
| | | | |
| protected: | | protected: | |
| void AddInternalItem(Item *item); | | void AddInternalItem(Item *item); | |
| | | | |
| public: | | public: | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 263 | | skipping to change at line 265 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetItemColor(); | | virtual Color & GetItemColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Color & GetItemFocusColor(); | | virtual Color & GetItemForegroundColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetSelectedItemColor(); | | virtual Color & GetSelectedItemColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetSelectedItemForegroundColor(); | | virtual Color & GetSelectedItemForegroundColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Color & GetItemForegroundColor(); | | virtual Color & GetItemFocusColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetItemForegroundFocusColor(); | | virtual Color & GetItemForegroundFocusColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual Color & GetDisabledItemColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Color & GetDisabledItemForegroundColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetItemColor(int red, int green, int blue, int
alpha); | | virtual void SetItemColor(int red, int green, int blue, int
alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetItemForegroundColor(int red, int green, int | |
| | | blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetItemFocusColor(int red, int green, int blue,
int alpha); | | virtual void SetItemFocusColor(int red, int green, int blue,
int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetItemForegroundFocusColor(int red, int green, | |
| | | int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetSelectedItemColor(int red, int green, int bl
ue, int alpha); | | virtual void SetSelectedItemColor(int red, int green, int bl
ue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetSelectedItemForegroundColor(int red, int gre
en, int blue, int alpha); | | virtual void SetSelectedItemForegroundColor(int red, int gre
en, int blue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetItemForegroundColor(int red, int green, int
blue, int alpha); | | virtual void SetDisabledItemColor(int red, int green, int bl
ue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetItemForegroundFocusColor(int red, int green,
int blue, int alpha); | | virtual void SetDisabledItemForegroundColor(int red, int gre
en, int blue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetItemColor(const Color &color); | | virtual void SetItemColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetItemForegroundColor(const Color &color); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetItemFocusColor(const Color &color); | | virtual void SetItemFocusColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetItemForegroundFocusColor(const Color &color) | |
| | | ; | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetSelectedItemColor(const Color &color); | | virtual void SetSelectedItemColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetSelectedItemForegroundColor(const Color &col
or); | | virtual void SetSelectedItemForegroundColor(const Color &col
or); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetItemForegroundColor(const Color &color); | | virtual void SetDisabledItemColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetItemForegroundFocusColor(const Color &color)
; | | virtual void SetDisabledItemForegroundColor(const Color &col
or); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual int GetItemsSize(); | | virtual int GetItemsSize(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
End of changes. 14 change blocks. |
| 14 lines changed or deleted | | 55 lines changed or added | |
|
| jkeyboard.h | | jkeyboard.h | |
| | | | |
| skipping to change at line 25 | | skipping to change at line 25 | |
| * You should have received a copy of the GNU General Public License
* | | * You should have received a copy of the GNU General Public License
* | |
| * along with this program; if not, write to the
* | | * along with this program; if not, write to the
* | |
| * Free Software Foundation, Inc.,
* | | * Free Software Foundation, Inc.,
* | |
| * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | |
| **************************************************************************
*/ | | **************************************************************************
*/ | |
| #ifndef J_KEYBOARD_H | | #ifndef J_KEYBOARD_H | |
| #define J_KEYBOARD_H | | #define J_KEYBOARD_H | |
| | | | |
| #include "jbutton.h" | | #include "jbutton.h" | |
| #include "jtextarea.h" | | #include "jtextarea.h" | |
|
| #include "jkeyboardlistener.h" | | #include "jkeyevent.h" | |
| | | #include "jframe.h" | |
| #include "jbuttonlistener.h" | | #include "jbuttonlistener.h" | |
|
| | | #include "jkeyboardlistener.h" | |
| #include "jtextlistener.h" | | #include "jtextlistener.h" | |
|
| #include "jframe.h" | | | |
| | | | |
| #include "jthread.h" | | #include "jthread.h" | |
| #include "jmutex.h" | | #include "jmutex.h" | |
| | | | |
| #include <string> | | #include <string> | |
| #include <iostream> | | #include <iostream> | |
| #include <vector> | | #include <vector> | |
| | | | |
| #include <stdlib.h> | | #include <stdlib.h> | |
| | | | |
| | | | |
| skipping to change at line 58 | | skipping to change at line 59 | |
| JKB_NUMERIC, | | JKB_NUMERIC, | |
| JKB_PHONE, | | JKB_PHONE, | |
| JKB_INTERNET | | JKB_INTERNET | |
| }; | | }; | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| * \author Jeff Ferr | | * \author Jeff Ferr | |
| */ | | */ | |
|
| class Keyboard : public jgui::Frame, public jgui::ButtonListener, public jg
ui::TextListener { | | class Keyboard : public jgui::Frame, public jgui::ButtonListener{ | |
| | | | |
| private: | | private: | |
| jthread::Mutex _key_mutex; | | jthread::Mutex _key_mutex; | |
| | | | |
| std::vector<KeyboardListener *> _keyboard_listeners; | | std::vector<KeyboardListener *> _keyboard_listeners; | |
|
| std::vector<Button *> _buttons; | | | |
| TextArea *display; | | TextArea *display; | |
|
| Component *_current_button; | | | |
| | | | |
| jkeyboard_type_t _type; | | jkeyboard_type_t _type; | |
| std::string _text; | | std::string _text; | |
| int delta, | | int delta, | |
| bx, | | bx, | |
| by, | | by, | |
| bwidth, | | bwidth, | |
| bheight, | | bheight, | |
| _state; | | _state; | |
| bool started, | | bool started, | |
| | | | |
| skipping to change at line 173 | | skipping to change at line 172 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void ActionPerformed(ButtonEvent *event); | | virtual void ActionPerformed(ButtonEvent *event); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void InputReceived(jgui::KeyEvent *event); | | virtual bool ProcessEvent(jgui::KeyEvent *event); | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void TextChanged(TextEvent *event); | | | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual std::vector<KeyboardListener *> & GetKeyboardListene
rs(); | | virtual std::vector<KeyboardListener *> & GetKeyboardListene
rs(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
| skipping to change at line 203 | | skipping to change at line 196 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void RemoveKeyboardListener(KeyboardListener *listen
er); | | virtual void RemoveKeyboardListener(KeyboardListener *listen
er); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void DispatchKeyboardEvent(KeyboardEvent *event); | | virtual void DispatchKeyboardEvent(KeyEvent *event); | |
| | | | |
| }; | | }; | |
| | | | |
| } | | } | |
| | | | |
| #endif | | #endif | |
| | | | |
End of changes. 8 change blocks. |
| 13 lines changed or deleted | | 6 lines changed or added | |
|
| jlocaldatagramsocket.h | | jlocaldatagramsocket.h | |
| | | | |
| skipping to change at line 53 | | skipping to change at line 53 | |
| */ | | */ | |
| class LocalDatagramSocket : public jsocket::Connection{ | | class LocalDatagramSocket : public jsocket::Connection{ | |
| | | | |
| private: | | private: | |
| /** \brief Socket handler. */ | | /** \brief Socket handler. */ | |
| #ifdef _WIN32 | | #ifdef _WIN32 | |
| #else | | #else | |
| int _fd; | | int _fd; | |
| #endif | | #endif | |
| /** \brief */ | | /** \brief */ | |
|
| | | struct sockaddr_un _server; | |
| | | /** \brief */ | |
| struct sockaddr_un _client; | | struct sockaddr_un _client; | |
| /** \brief */ | | /** \brief */ | |
|
| struct sockaddr_un _server; | | struct sockaddr_un _from; | |
| /** \brief Input stream. */ | | /** \brief Input stream. */ | |
| SocketInputStream *_is; | | SocketInputStream *_is; | |
| /** \brief Output stream. */ | | /** \brief Output stream. */ | |
| SocketOutputStream *_os; | | SocketOutputStream *_os; | |
| /** \brief */ | | /** \brief */ | |
|
| std::string _client_file; | | | |
| /** \brief */ | | | |
| std::string _server_file; | | std::string _server_file; | |
|
| | | /** \brief */ | |
| | | std::string _client_file; | |
| /** \brief Bytes sent. */ | | /** \brief Bytes sent. */ | |
| int64_t _sent_bytes; | | int64_t _sent_bytes; | |
| /** \brief Bytes received. */ | | /** \brief Bytes received. */ | |
| int64_t _receive_bytes; | | int64_t _receive_bytes; | |
|
| /** \brief Connect or not ? */ | | | |
| bool _stream; | | | |
| /** \brief */ | | /** \brief */ | |
| int _timeout; | | int _timeout; | |
| | | | |
| /** | | /** | |
| * \brief Create a new socket. | | * \brief Create a new socket. | |
| * | | * | |
| */ | | */ | |
| void CreateSocket(); | | void CreateSocket(); | |
| | | | |
| /** | | /** | |
| | | | |
| skipping to change at line 99 | | skipping to change at line 99 | |
| void ConnectSocket(); | | void ConnectSocket(); | |
| | | | |
| /** | | /** | |
| * \brief Init the stream. | | * \brief Init the stream. | |
| * | | * | |
| */ | | */ | |
| void InitStream(int rbuf_, int wbuf_); | | void InitStream(int rbuf_, int wbuf_); | |
| | | | |
| public: | | public: | |
| /** | | /** | |
|
| * \brief Construtor UDP client. | | * \brief Construtor UDP Server. | |
| * | | * | |
| */ | | */ | |
|
| LocalDatagramSocket(std::string client, std::string server,
int timeout_ = 0, int rbuf_ = 65535, int wbuf_ = 4096); | | LocalDatagramSocket(std::string server, int timeout_ = 0, in
t rbuf_ = 65535, int wbuf_ = 4096); | |
| | | | |
| /** | | /** | |
|
| * \brief Construtor UDP server. | | * \brief Construtor UDP Client. | |
| * | | * | |
| */ | | */ | |
|
| LocalDatagramSocket(std::string server, int timeout_ = 0, in
t rbuf_ = 65535, int wbuf_ = 4096); | | LocalDatagramSocket(std::string client, std::string server,
int timeout_ = 0, int rbuf_ = 65535, int wbuf_ = 4096); | |
| | | | |
| /** | | /** | |
| * \brief Destructor virtual. | | * \brief Destructor virtual. | |
| * | | * | |
| */ | | */ | |
| virtual ~LocalDatagramSocket(); | | virtual ~LocalDatagramSocket(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
| skipping to change at line 189 | | skipping to change at line 189 | |
| */ | | */ | |
| virtual int64_t GetSentBytes(); | | virtual int64_t GetSentBytes(); | |
| | | | |
| /** | | /** | |
| * \brief Get received bytes from a source. | | * \brief Get received bytes from a source. | |
| * | | * | |
| */ | | */ | |
| virtual int64_t GetReadedBytes(); | | virtual int64_t GetReadedBytes(); | |
| | | | |
| /** | | /** | |
|
| * \brief Get a object SocketOption. | | * \brief Get a object SocketOptions. | |
| * | | * | |
| */ | | */ | |
|
| SocketOption * GetSocketOption(); | | SocketOptions * GetSocketOptions(); | |
| | | | |
| }; | | }; | |
| | | | |
| } | | } | |
| | | | |
| #endif | | #endif | |
| | | | |
End of changes. 11 change blocks. |
| 11 lines changed or deleted | | 11 lines changed or added | |
|
| jnullgraphics.h | | jnullgraphics.h | |
| | | | |
| skipping to change at line 59 | | skipping to change at line 59 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void * GetNativeSurface(); | | virtual void * GetNativeSurface(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| static bool GetImageSize(std::string img, int *width, int *h | | | |
| eight); | | | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void SetNativeSurface(void *surface); | | virtual void SetNativeSurface(void *surface); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetWorkingScreenSize(int width, int height); | | virtual void SetWorkingScreenSize(int width, int height); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual jsize_t GetWorkingScreenSize(); | | virtual jsize_t GetWorkingScreenSize(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Image * Create(); | | | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void Rotate(double radians); | | virtual void Rotate(double radians); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void Translate(int x, int y); | | virtual void Translate(int x, int y); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 185 | | skipping to change at line 173 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetColor(const Color &color); | | virtual void SetColor(const Color &color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetColor(uint32_t c); | | virtual void SetColor(uint32_t color); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetColor(int r, int g, int b, int a = 0xff); | | virtual void SetColor(int red, int green, int blue, int alph
a = 0xff); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual bool HasFont(); | | virtual bool HasFont(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
| skipping to change at line 537 | | skipping to change at line 525 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual uint32_t GetRGB(int xp, int yp, uint32_t pixel = 0xf
f000000); | | virtual uint32_t GetRGB(int xp, int yp, uint32_t pixel = 0xf
f000000); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void GetRGB(uint32_t **rgb, int xp, int yp, int wp,
int hp, int scansize); | | virtual void GetRGB(uint32_t **rgb, int startxp, int startyp
, int widthp, int heightp, int scansize); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetRGB(uint32_t rgb, int xp, int yp); | | virtual void SetRGB(uint32_t rgb, int xp, int yp); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetRGB(uint32_t *rgb, int xp, int yp, int wp, i
nt hp, int scanline); | | virtual void SetRGB(uint32_t *rgb, int xp, int yp, int wp, i
nt hp, int scanline); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void Reset(); | | virtual void Reset(); | |
| | | | |
|
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void Lock(); | | | |
| | | | |
| /** | | | |
| * \brief | | | |
| * | | | |
| */ | | | |
| virtual void Unlock(); | | | |
| | | | |
| }; | | }; | |
| | | | |
| } | | } | |
| | | | |
| #endif | | #endif | |
| | | | |
End of changes. 6 change blocks. |
| 28 lines changed or deleted | | 3 lines changed or added | |
|
| jpointer.h | | jpointer.h | |
| | | | |
| skipping to change at line 62 | | skipping to change at line 62 | |
| * Como eh necessario saber o tipo do objeto para | | * Como eh necessario saber o tipo do objeto para | |
| * destrui-lo e nao seria possivel utilizar template | | * destrui-lo e nao seria possivel utilizar template | |
| * pelos motivos citados acima e nao ha uma superclasse | | * pelos motivos citados acima e nao ha uma superclasse | |
| * comum a todos os objetos em C++, a solucao foi realizar | | * comum a todos os objetos em C++, a solucao foi realizar | |
| * a contagem por meio do valor numerico do endereco | | * a contagem por meio do valor numerico do endereco | |
| * (posicao de memoria) do objeto. Quando o contador zera, | | * (posicao de memoria) do objeto. Quando o contador zera, | |
| * o ptr correspondente se encarrega de destruir o objeto. | | * o ptr correspondente se encarrega de destruir o objeto. | |
| * | | * | |
| * Essa classe nao eh thread-safe. | | * Essa classe nao eh thread-safe. | |
| * | | * | |
|
| * \aithor Tiago Dias Carvalho do Nascimento (tiagocomputacao@yahoo.com.br) | | * \author Tiago Dias Carvalho do Nascimento (tiagocomputacao@yahoo.com.br) | |
| */ | | */ | |
| class ReferenceCounter { | | class ReferenceCounter { | |
| | | | |
| private: | | private: | |
| /** | | /** | |
| * Instancia do singleton. | | * Instancia do singleton. | |
| */ | | */ | |
| static ReferenceCounter *_instance; | | static ReferenceCounter *_instance; | |
| | | | |
| /** | | /** | |
| | | | |
| skipping to change at line 154 | | skipping to change at line 154 | |
| * trabalhar com vetores. | | * trabalhar com vetores. | |
| * | | * | |
| * Eh provavel que essa classe seja thread-safe, desde que nao haja | | * Eh provavel que essa classe seja thread-safe, desde que nao haja | |
| * ponteiros normais apontando para posicoes apontadas por algum ptr. | | * ponteiros normais apontando para posicoes apontadas por algum ptr. | |
| * Esse comportamento eh esperado porque, para haver a possibilidade de | | * Esse comportamento eh esperado porque, para haver a possibilidade de | |
| * erro de concorrencia nesse caso, eh necessario que mais de uma thread | | * erro de concorrencia nesse caso, eh necessario que mais de uma thread | |
| * acesse uma variavel compartilhada. Mas, se um endereco eh compartilhado, | | * acesse uma variavel compartilhada. Mas, se um endereco eh compartilhado, | |
| * entao existe um ptr, de escopo nao menos amplo que o das threads, | | * entao existe um ptr, de escopo nao menos amplo que o das threads, | |
| * referenciado o mesmo endereco. | | * referenciado o mesmo endereco. | |
| | | | |
|
| * \aithor Tiago Dias Carvalho do Nascimento (tiagocomputacao@yahoo.com.br) | | * \author Tiago Dias Carvalho do Nascimento (tiagocomputacao@yahoo.com.br) | |
| */ | | */ | |
| | | | |
| template <class X> class ptr { | | template <class X> class ptr { | |
| | | | |
| private: | | private: | |
| /** \brief O endereco do objeto referenciado por este "ponte
iro" */ | | /** \brief O endereco do objeto referenciado por este "ponte
iro" */ | |
| X *_pointer; | | X *_pointer; | |
| | | | |
| /** | | /** | |
| * \brief Aponta para o novo endereco e incrementa o contado
r correspondente. | | * \brief Aponta para o novo endereco e incrementa o contado
r correspondente. | |
| | | | |
End of changes. 2 change blocks. |
| 2 lines changed or deleted | | 2 lines changed or added | |
|
| jsocket.h | | jsocket.h | |
| | | | |
| skipping to change at line 25 | | skipping to change at line 25 | |
| * You should have received a copy of the GNU General Public License
* | | * You should have received a copy of the GNU General Public License
* | |
| * along with this program; if not, write to the
* | | * along with this program; if not, write to the
* | |
| * Free Software Foundation, Inc.,
* | | * Free Software Foundation, Inc.,
* | |
| * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | |
| **************************************************************************
*/ | | **************************************************************************
*/ | |
| #ifndef J_SOCKET_H | | #ifndef J_SOCKET_H | |
| #define J_SOCKET_H | | #define J_SOCKET_H | |
| | | | |
| #include "jinetaddress.h" | | #include "jinetaddress.h" | |
| #include "jserversocket.h" | | #include "jserversocket.h" | |
|
| #include "jsocketoption.h" | | #include "jsocketoptions.h" | |
| #include "jsocketinputstream.h" | | #include "jsocketinputstream.h" | |
| #include "jsocketoutputstream.h" | | #include "jsocketoutputstream.h" | |
| #include "jconnection.h" | | #include "jconnection.h" | |
| | | | |
| #include "jobject.h" | | #include "jobject.h" | |
| | | | |
| #include <iostream> | | #include <iostream> | |
| | | | |
| #ifdef _WIN32 | | #ifdef _WIN32 | |
| #include <windows.h> | | #include <windows.h> | |
| | | | |
| skipping to change at line 68 | | skipping to change at line 68 | |
| jsocket_t _fd; | | jsocket_t _fd; | |
| /** \brief */ | | /** \brief */ | |
| SocketInputStream *_is; | | SocketInputStream *_is; | |
| /** \brief */ | | /** \brief */ | |
| SocketOutputStream *_os; | | SocketOutputStream *_os; | |
| /** \brief */ | | /** \brief */ | |
| struct sockaddr_in _lsock; | | struct sockaddr_in _lsock; | |
| /** \brief */ | | /** \brief */ | |
| struct sockaddr_in _server_sock; | | struct sockaddr_in _server_sock; | |
| /** \brief */ | | /** \brief */ | |
|
| | | InetAddress *_local; | |
| | | /** \brief */ | |
| InetAddress *_address; | | InetAddress *_address; | |
| /** \brief Bytes sent. */ | | /** \brief Bytes sent. */ | |
| int64_t _sent_bytes; | | int64_t _sent_bytes; | |
| /** \brief Bytes received. */ | | /** \brief Bytes received. */ | |
| int64_t _receive_bytes; | | int64_t _receive_bytes; | |
| /** \brief */ | | /** \brief */ | |
| int _timeout; | | int _timeout; | |
| | | | |
| /** | | /** | |
| * \brief Create a new socket. | | * \brief Create a new socket. | |
| | | | |
| skipping to change at line 224 | | skipping to change at line 226 | |
| /** | | /** | |
| * \brief Get de bytes received from a source. | | * \brief Get de bytes received from a source. | |
| * | | * | |
| */ | | */ | |
| virtual int64_t GetReadedBytes(); | | virtual int64_t GetReadedBytes(); | |
| | | | |
| /** | | /** | |
| * \brief Get the socket options. | | * \brief Get the socket options. | |
| * | | * | |
| */ | | */ | |
|
| SocketOption * GetSocketOption(); | | SocketOptions * GetSocketOptions(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual std::string what(); | | virtual std::string what(); | |
| | | | |
| }; | | }; | |
| | | | |
| } | | } | |
| | | | |
End of changes. 3 change blocks. |
| 2 lines changed or deleted | | 4 lines changed or added | |
|
| jsslsocket.h | | jsslsocket.h | |
| | | | |
| skipping to change at line 25 | | skipping to change at line 25 | |
| * You should have received a copy of the GNU General Public License
* | | * You should have received a copy of the GNU General Public License
* | |
| * along with this program; if not, write to the
* | | * along with this program; if not, write to the
* | |
| * Free Software Foundation, Inc.,
* | | * Free Software Foundation, Inc.,
* | |
| * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | |
| **************************************************************************
*/ | | **************************************************************************
*/ | |
| #ifndef J_SSLSOCKET_H | | #ifndef J_SSLSOCKET_H | |
| #define J_SSLSOCKET_H | | #define J_SSLSOCKET_H | |
| | | | |
| #include "jinetaddress.h" | | #include "jinetaddress.h" | |
| #include "jserversocket.h" | | #include "jserversocket.h" | |
|
| #include "jsocketoption.h" | | #include "jsocketoptions.h" | |
| #include "jsslsocketinputstream.h" | | #include "jsslsocketinputstream.h" | |
| #include "jsslsocketoutputstream.h" | | #include "jsslsocketoutputstream.h" | |
| #include "jconnection.h" | | #include "jconnection.h" | |
| | | | |
| #ifdef _WIN32 | | #ifdef _WIN32 | |
| #include <windows.h> | | #include <windows.h> | |
| #else | | #else | |
| #include <sys/socket.h> | | #include <sys/socket.h> | |
| #include <openssl/ssl.h> | | #include <openssl/ssl.h> | |
| #include <openssl/x509.h> | | #include <openssl/x509.h> | |
| | | | |
| skipping to change at line 88 | | skipping to change at line 88 | |
| jsocket_t _fd; | | jsocket_t _fd; | |
| /** \brief */ | | /** \brief */ | |
| SSLSocketInputStream *_is; | | SSLSocketInputStream *_is; | |
| /** \brief */ | | /** \brief */ | |
| SSLSocketOutputStream *_os; | | SSLSocketOutputStream *_os; | |
| /** \brief */ | | /** \brief */ | |
| sockaddr_in _lsock; | | sockaddr_in _lsock; | |
| /** \brief */ | | /** \brief */ | |
| sockaddr_in _server_sock; | | sockaddr_in _server_sock; | |
| /** \brief */ | | /** \brief */ | |
|
| | | InetAddress *_local; | |
| | | /** \brief */ | |
| InetAddress *_address; | | InetAddress *_address; | |
| /** \brief Bytes sent. */ | | /** \brief Bytes sent. */ | |
| int64_t _sent_bytes; | | int64_t _sent_bytes; | |
| /** \brief Bytes received. */ | | /** \brief Bytes received. */ | |
| int64_t _receive_bytes; | | int64_t _receive_bytes; | |
| /** \brief */ | | /** \brief */ | |
| int _timeout; | | int _timeout; | |
| | | | |
| /** | | /** | |
| * \brief Create a new socket. | | * \brief Create a new socket. | |
| | | | |
| skipping to change at line 280 | | skipping to change at line 282 | |
| /** | | /** | |
| * \brief Get de bytes received from a source. | | * \brief Get de bytes received from a source. | |
| * | | * | |
| */ | | */ | |
| virtual int64_t GetReadedBytes(); | | virtual int64_t GetReadedBytes(); | |
| | | | |
| /** | | /** | |
| * \brief Get the socket options. | | * \brief Get the socket options. | |
| * | | * | |
| */ | | */ | |
|
| SocketOption * GetSocketOption(); | | SocketOptions * GetSocketOptions(); | |
| | | | |
| /** | | /** | |
| * Cert files (if not set, a temporary RSA session cert will
be created if needed) | | * Cert files (if not set, a temporary RSA session cert will
be created if needed) | |
| * | | * | |
| * PEM format | | * PEM format | |
| */ | | */ | |
| bool UseCert(const char *cert_file, const char *private_key_
file); | | bool UseCert(const char *cert_file, const char *private_key_
file); | |
| | | | |
| /** | | /** | |
| * As use_cert() but also give pasord for private_key_file (
or get OpenSSL's standard prompt each time) | | * As use_cert() but also give pasord for private_key_file (
or get OpenSSL's standard prompt each time) | |
| | | | |
End of changes. 3 change blocks. |
| 2 lines changed or deleted | | 4 lines changed or added | |
|
| jsslsocket6.h | | jsslsocket6.h | |
| | | | |
| skipping to change at line 25 | | skipping to change at line 25 | |
| * You should have received a copy of the GNU General Public License
* | | * You should have received a copy of the GNU General Public License
* | |
| * along with this program; if not, write to the
* | | * along with this program; if not, write to the
* | |
| * Free Software Foundation, Inc.,
* | | * Free Software Foundation, Inc.,
* | |
| * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* | |
| **************************************************************************
*/ | | **************************************************************************
*/ | |
| #ifndef J_SSLSOCKET6_H | | #ifndef J_SSLSOCKET6_H | |
| #define J_SSLSOCKET6_H | | #define J_SSLSOCKET6_H | |
| | | | |
| #include "jinetaddress.h" | | #include "jinetaddress.h" | |
| #include "jserversocket6.h" | | #include "jserversocket6.h" | |
|
| #include "jsocketoption.h" | | #include "jsocketoptions.h" | |
| #include "jsslsocketinputstream.h" | | #include "jsslsocketinputstream.h" | |
| #include "jsslsocketoutputstream.h" | | #include "jsslsocketoutputstream.h" | |
| #include "jconnection.h" | | #include "jconnection.h" | |
| | | | |
| #ifdef _WIN32 | | #ifdef _WIN32 | |
| #include <windows.h> | | #include <windows.h> | |
| #else | | #else | |
| #include <sys/socket.h> | | #include <sys/socket.h> | |
| #include <openssl/ssl.h> | | #include <openssl/ssl.h> | |
| #include <openssl/x509.h> | | #include <openssl/x509.h> | |
| | | | |
| skipping to change at line 276 | | skipping to change at line 276 | |
| /** | | /** | |
| * \brief Get de bytes received from a source. | | * \brief Get de bytes received from a source. | |
| * | | * | |
| */ | | */ | |
| virtual int64_t GetReadedBytes(); | | virtual int64_t GetReadedBytes(); | |
| | | | |
| /** | | /** | |
| * \brief Get the socket options. | | * \brief Get the socket options. | |
| * | | * | |
| */ | | */ | |
|
| SocketOption * GetSocketOption(); | | SocketOptions * GetSocketOptions(); | |
| | | | |
| /** | | /** | |
| * Cert files (if not set, a temporary RSA session cert will
be created if needed) | | * Cert files (if not set, a temporary RSA session cert will
be created if needed) | |
| * | | * | |
| * PEM format | | * PEM format | |
| */ | | */ | |
| bool UseCert(const char *cert_file, const char *private_key_
file); | | bool UseCert(const char *cert_file, const char *private_key_
file); | |
| | | | |
| /** | | /** | |
| * As use_cert() but also give pasord for private_key_file (
or get OpenSSL's standard prompt each time) | | * As use_cert() but also give pasord for private_key_file (
or get OpenSSL's standard prompt each time) | |
| | | | |
End of changes. 2 change blocks. |
| 2 lines changed or deleted | | 2 lines changed or added | |
|
| jtheme.h | | jtheme.h | |
| | | | |
| skipping to change at line 50 | | skipping to change at line 50 | |
| class Theme : public jcommon::Object{ | | class Theme : public jcommon::Object{ | |
| | | | |
| friend class ThemeManager; | | friend class ThemeManager; | |
| friend class Component; | | friend class Component; | |
| friend class Window; | | friend class Window; | |
| friend class ItemComponent; | | friend class ItemComponent; | |
| friend class Frame; | | friend class Frame; | |
| | | | |
| private: | | private: | |
| Font *_window_font, | | Font *_window_font, | |
|
| *_component_font; | | *_component_font; | |
| jinsets_t _insets; | | jinsets_t _insets; | |
| Color _window_bgcolor, | | Color _window_bgcolor, | |
|
| _window_fgcolor, | | _window_fgcolor, | |
| _window_border_color, | | _window_border_color, | |
| _component_bgcolor, | | _component_bgcolor, | |
| _component_fgcolor, | | _component_fgcolor, | |
| _component_border_color, | | _component_border_color, | |
| _component_border_focus_color, | | _component_border_focus_color, | |
| _component_focus_bgcolor, | | _component_focus_bgcolor, | |
| _component_focus_fgcolor, | | _component_focus_fgcolor, | |
| _item_color, | | _component_scrollbar_color, | |
| _item_focus_color, | | _component_disabled_bgcolor, | |
| _item_selected_color, | | _component_disabled_fgcolor, | |
| _item_selected_fgcolor, | | _component_disabled_border_color, | |
| _item_fgcolor, | | _item_color, | |
| _item_focus_fgcolor; | | _item_fgcolor, | |
| | | _item_focus_color, | |
| | | _item_focus_fgcolor, | |
| | | _item_selected_color, | |
| | | _item_selected_fgcolor, | |
| | | _item_disabled_color, | |
| | | _item_disabled_fgcolor; | |
| jcomponent_border_t _component_border, | | jcomponent_border_t _component_border, | |
|
|
_window_border; | | _window_border; | |
| int _window_border_size, | | int _window_border_size, | |
|
| _component_border_size; | | _component_border_size; | |
| | | | |
| public: | | public: | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| Theme(); | | Theme(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| | | | |
| skipping to change at line 149 | | skipping to change at line 155 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetComponentForegroundFocusColor(int red, int g
reen, int blue, int alpha); | | virtual void SetComponentForegroundFocusColor(int red, int g
reen, int blue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetComponentScrollbarColor(int red, int green, | |
| | | int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetComponentDisabledBackgroundColor(int red, in | |
| | | t green, int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetComponentDisabledForegroundColor(int red, in | |
| | | t green, int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual void SetComponentDisabledBorderColor(int red, int gr | |
| | | een, int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetItemColor(int red, int green, int blue, int
alpha); | | virtual void SetItemColor(int red, int green, int blue, int
alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetItemForegroundColor(int red, int green, int | |
| | | blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetItemFocusColor(int red, int green, int blue,
int alpha); | | virtual void SetItemFocusColor(int red, int green, int blue,
int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual void SetItemForegroundFocusColor(int red, int green, | |
| | | int blue, int alpha); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual void SetSelectedItemColor(int red, int green, int bl
ue, int alpha); | | virtual void SetSelectedItemColor(int red, int green, int bl
ue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetSelectedItemForegroundColor(int red, int gre
en, int blue, int alpha); | | virtual void SetSelectedItemForegroundColor(int red, int gre
en, int blue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetItemForegroundColor(int red, int green, int
blue, int alpha); | | virtual void SetDisabledItemColor(int red, int green, int bl
ue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual void SetItemForegroundFocusColor(int red, int green,
int blue, int alpha); | | virtual void SetDisabledItemForegroundColor(int red, int gre
en, int blue, int alpha); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual void SetComponentBorder(jcomponent_border_t border); | | virtual void SetComponentBorder(jcomponent_border_t border); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
| skipping to change at line 281 | | skipping to change at line 323 | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetComponentForegroundFocusColor(); | | virtual Color & GetComponentForegroundFocusColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual Color & GetComponentScrollbarColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Color & GetComponentDisabledBackgroundColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Color & GetComponentDisabledForegroundColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| | | virtual Color & GetComponentDisabledBorderColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual Color & GetItemColor(); | | virtual Color & GetItemColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual Color & GetItemForegroundColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual Color & GetItemFocusColor(); | | virtual Color & GetItemFocusColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| | | virtual Color & GetItemForegroundFocusColor(); | |
| | | | |
| | | /** | |
| | | * \brief | |
| | | * | |
| | | */ | |
| virtual Color & GetSelectedItemColor(); | | virtual Color & GetSelectedItemColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual Color & GetSelectedItemForegroundColor(); | | virtual Color & GetSelectedItemForegroundColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Color & GetItemForegroundColor(); | | virtual Color & GetDisabledItemColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
|
| virtual Color & GetItemForegroundFocusColor(); | | virtual Color & GetDisabledItemForegroundColor(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| */ | | */ | |
| virtual jcomponent_border_t GetComponentBorder(); | | virtual jcomponent_border_t GetComponentBorder(); | |
| | | | |
| /** | | /** | |
| * \brief | | * \brief | |
| * | | * | |
| | | | |
End of changes. 14 change blocks. |
| 21 lines changed or deleted | | 105 lines changed or added | |
|