├── qyplayer ├── main.cpp ├── qyplayer.layout └── qyplayer.cbp ├── snapshots ├── 1.png ├── 2.jpg └── 3.jpg ├── gtkduilib ├── UIList.h ├── UIControl.h ├── UIDefine.h ├── UIList.cpp ├── UIRender.cpp ├── UIWindow.cpp ├── UIWindow.h ├── NotifyPump.cpp ├── ResourceMgr.h ├── UIContainer.h ├── UITabLayout.h ├── UITileLayout.h ├── DialogBuilder.cpp ├── UIChildLayout.h ├── UIContainer.cpp ├── UIScrollBar.cpp ├── UITileLayout.cpp ├── WindowImpBase.cpp ├── WindowImpBase.h ├── UIVerticalLayout.h ├── UIHorizontalLayout.cpp ├── UIHorizontalLayout.h ├── UIVerticalLayout.cpp ├── UIEvent.cpp ├── stdafx.cpp ├── stdafx.h ├── NotifyPump.h ├── UIText.h ├── DialogBuilder.h ├── UIFont.h ├── UIProgress.h ├── UILib.h ├── UILabel.h ├── ReadMe.txt ├── UISlider.h ├── UIEvent.h ├── UIOption.h ├── UIChildLayout.cpp ├── UIButton.h ├── UIRef.h ├── UIRender.h ├── UIFont.cpp ├── UIUtils.h ├── pugiconfig.hpp ├── UIString.h ├── UIText.cpp ├── UIProgress.cpp ├── gtkduilib.cbp ├── UIScrollBar.h ├── compat.h ├── UITabLayout.cpp ├── UILabel.cpp ├── ResourceMgr.cpp ├── gtkduilib.layout ├── UIOption.cpp ├── UISlider.cpp └── gtkduilib.vcproj ├── skin ├── qyplayer │ ├── logo.png │ ├── scroll.png │ ├── theme.jpg │ ├── SliderBg.png │ ├── btn_close.png │ ├── btn_mini.png │ ├── btn_play.png │ ├── btn_skin.png │ ├── logo_text.png │ ├── slider_bg.png │ ├── btn_setting.png │ ├── btn_volume.png │ ├── main_title.png │ ├── thumb_down.png │ ├── thumb_over.png │ ├── HSliderChannel.png │ ├── album_frame_bg.png │ ├── btn_minimize.png │ ├── btn_play_next.png │ ├── btn_play_prev.png │ ├── play_slider_bg.png │ ├── slider_value.png │ ├── thumb_normal.png │ ├── list_header_sep.png │ ├── btn_play_mode_next.png │ ├── btn_play_mode_rand.png │ ├── play_slider_bg_fix.png │ ├── play_slider_cache.png │ ├── play_slider_thumb.png │ ├── play_slider_thumb_1.png │ ├── play_slider_value.png │ ├── play_slider_value2.png │ ├── song_list_title_bg.png │ ├── btn_play_mode_circle.png │ ├── btn_play_mode_single.png │ ├── common_scroll_thumb_mask.png │ ├── play_slider_value2_fix.png │ ├── song_list_title_btn_bg.png │ ├── volume_slider_thumb_mini.png │ ├── play_slider_thumb_animate.png │ ├── btn_play_mode_single_circle.png │ ├── play_slider_thumb_animate_1.png │ ├── 7CA3EE8F40384DC0C6FB2ACF69EE9AD9.jpg │ ├── qyplayer.uiproj │ ├── music_list.xml │ ├── test1.xml │ ├── PlayerMain1.xml │ ├── PlayerMain.xml │ └── PlayerMain2.xml └── 360SafeRes │ ├── icon.ico │ ├── icon.png │ ├── logo.png │ ├── cloud.png │ ├── commmon.png │ ├── start.png │ ├── antivirus.png │ ├── firewall.png │ ├── scrollbar.bmp │ ├── button_hover.png │ ├── firewall_ok.png │ ├── scanbutton.png │ ├── sys_dlg_max.png │ ├── sys_dlg_menu.png │ ├── sys_dlg_min.png │ ├── tabbar_hover.png │ ├── button_normal.png │ ├── button_pushed.png │ ├── navigationbar.bmp │ ├── networkshield.png │ ├── preventnumber.png │ ├── sys_dlg_close.png │ ├── tabbar_normal.png │ ├── tabbar_pushed.png │ ├── toolbar_hover.png │ ├── toolbar_normal.png │ ├── toolbar_pushed.png │ ├── horizontal_border.bmp │ ├── softwaremanager.png │ ├── sys_dlg_restore.png │ ├── vertical_border.bmp │ ├── examine_background.bmp │ ├── ComputerExamine.xml │ └── ComputerExamine2.xml ├── gtkduilib_test ├── stdafx.cpp ├── stdafx.h ├── targetver.h ├── gtkduilib_test.layout ├── ReadMe.txt ├── gtkduilib_test.cbp ├── gtkduilib_test.vcproj └── gtkduilib_test.cpp ├── gtkduilib.workspace ├── 360Demo ├── 360Demo.layout ├── 360Demo.cbp └── main.cpp ├── README.md ├── gtkduilib.workspace.layout ├── gtkduilib.sln └── .gitignore /qyplayer/main.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/qyplayer/main.cpp -------------------------------------------------------------------------------- /snapshots/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/snapshots/1.png -------------------------------------------------------------------------------- /snapshots/2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/snapshots/2.jpg -------------------------------------------------------------------------------- /snapshots/3.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/snapshots/3.jpg -------------------------------------------------------------------------------- /gtkduilib/UIList.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIList.h -------------------------------------------------------------------------------- /gtkduilib/UIControl.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIControl.h -------------------------------------------------------------------------------- /gtkduilib/UIDefine.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIDefine.h -------------------------------------------------------------------------------- /gtkduilib/UIList.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIList.cpp -------------------------------------------------------------------------------- /gtkduilib/UIRender.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIRender.cpp -------------------------------------------------------------------------------- /gtkduilib/UIWindow.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIWindow.cpp -------------------------------------------------------------------------------- /gtkduilib/UIWindow.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIWindow.h -------------------------------------------------------------------------------- /skin/qyplayer/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/logo.png -------------------------------------------------------------------------------- /gtkduilib/NotifyPump.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/NotifyPump.cpp -------------------------------------------------------------------------------- /gtkduilib/ResourceMgr.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/ResourceMgr.h -------------------------------------------------------------------------------- /gtkduilib/UIContainer.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIContainer.h -------------------------------------------------------------------------------- /gtkduilib/UITabLayout.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UITabLayout.h -------------------------------------------------------------------------------- /gtkduilib/UITileLayout.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UITileLayout.h -------------------------------------------------------------------------------- /skin/360SafeRes/icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/icon.ico -------------------------------------------------------------------------------- /skin/360SafeRes/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/icon.png -------------------------------------------------------------------------------- /skin/360SafeRes/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/logo.png -------------------------------------------------------------------------------- /skin/qyplayer/scroll.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/scroll.png -------------------------------------------------------------------------------- /skin/qyplayer/theme.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/theme.jpg -------------------------------------------------------------------------------- /gtkduilib/DialogBuilder.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/DialogBuilder.cpp -------------------------------------------------------------------------------- /gtkduilib/UIChildLayout.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIChildLayout.h -------------------------------------------------------------------------------- /gtkduilib/UIContainer.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIContainer.cpp -------------------------------------------------------------------------------- /gtkduilib/UIScrollBar.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIScrollBar.cpp -------------------------------------------------------------------------------- /gtkduilib/UITileLayout.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UITileLayout.cpp -------------------------------------------------------------------------------- /gtkduilib/WindowImpBase.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/WindowImpBase.cpp -------------------------------------------------------------------------------- /gtkduilib/WindowImpBase.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/WindowImpBase.h -------------------------------------------------------------------------------- /skin/360SafeRes/cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/cloud.png -------------------------------------------------------------------------------- /skin/360SafeRes/commmon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/commmon.png -------------------------------------------------------------------------------- /skin/360SafeRes/start.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/start.png -------------------------------------------------------------------------------- /skin/qyplayer/SliderBg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/SliderBg.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_close.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_mini.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_mini.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_play.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_skin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_skin.png -------------------------------------------------------------------------------- /skin/qyplayer/logo_text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/logo_text.png -------------------------------------------------------------------------------- /skin/qyplayer/slider_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/slider_bg.png -------------------------------------------------------------------------------- /gtkduilib/UIVerticalLayout.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIVerticalLayout.h -------------------------------------------------------------------------------- /skin/360SafeRes/antivirus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/antivirus.png -------------------------------------------------------------------------------- /skin/360SafeRes/firewall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/firewall.png -------------------------------------------------------------------------------- /skin/360SafeRes/scrollbar.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/scrollbar.bmp -------------------------------------------------------------------------------- /skin/qyplayer/btn_setting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_setting.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_volume.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_volume.png -------------------------------------------------------------------------------- /skin/qyplayer/main_title.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/main_title.png -------------------------------------------------------------------------------- /skin/qyplayer/thumb_down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/thumb_down.png -------------------------------------------------------------------------------- /skin/qyplayer/thumb_over.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/thumb_over.png -------------------------------------------------------------------------------- /gtkduilib/UIHorizontalLayout.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIHorizontalLayout.cpp -------------------------------------------------------------------------------- /gtkduilib/UIHorizontalLayout.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIHorizontalLayout.h -------------------------------------------------------------------------------- /gtkduilib/UIVerticalLayout.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/gtkduilib/UIVerticalLayout.cpp -------------------------------------------------------------------------------- /skin/360SafeRes/button_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/button_hover.png -------------------------------------------------------------------------------- /skin/360SafeRes/firewall_ok.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/firewall_ok.png -------------------------------------------------------------------------------- /skin/360SafeRes/scanbutton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/scanbutton.png -------------------------------------------------------------------------------- /skin/360SafeRes/sys_dlg_max.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/sys_dlg_max.png -------------------------------------------------------------------------------- /skin/360SafeRes/sys_dlg_menu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/sys_dlg_menu.png -------------------------------------------------------------------------------- /skin/360SafeRes/sys_dlg_min.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/sys_dlg_min.png -------------------------------------------------------------------------------- /skin/360SafeRes/tabbar_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/tabbar_hover.png -------------------------------------------------------------------------------- /skin/qyplayer/HSliderChannel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/HSliderChannel.png -------------------------------------------------------------------------------- /skin/qyplayer/album_frame_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/album_frame_bg.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_minimize.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_minimize.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_play_next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play_next.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_play_prev.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play_prev.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_bg.png -------------------------------------------------------------------------------- /skin/qyplayer/slider_value.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/slider_value.png -------------------------------------------------------------------------------- /skin/qyplayer/thumb_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/thumb_normal.png -------------------------------------------------------------------------------- /skin/360SafeRes/button_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/button_normal.png -------------------------------------------------------------------------------- /skin/360SafeRes/button_pushed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/button_pushed.png -------------------------------------------------------------------------------- /skin/360SafeRes/navigationbar.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/navigationbar.bmp -------------------------------------------------------------------------------- /skin/360SafeRes/networkshield.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/networkshield.png -------------------------------------------------------------------------------- /skin/360SafeRes/preventnumber.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/preventnumber.png -------------------------------------------------------------------------------- /skin/360SafeRes/sys_dlg_close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/sys_dlg_close.png -------------------------------------------------------------------------------- /skin/360SafeRes/tabbar_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/tabbar_normal.png -------------------------------------------------------------------------------- /skin/360SafeRes/tabbar_pushed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/tabbar_pushed.png -------------------------------------------------------------------------------- /skin/360SafeRes/toolbar_hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/toolbar_hover.png -------------------------------------------------------------------------------- /skin/360SafeRes/toolbar_normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/toolbar_normal.png -------------------------------------------------------------------------------- /skin/360SafeRes/toolbar_pushed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/toolbar_pushed.png -------------------------------------------------------------------------------- /skin/qyplayer/list_header_sep.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/list_header_sep.png -------------------------------------------------------------------------------- /skin/360SafeRes/horizontal_border.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/horizontal_border.bmp -------------------------------------------------------------------------------- /skin/360SafeRes/softwaremanager.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/softwaremanager.png -------------------------------------------------------------------------------- /skin/360SafeRes/sys_dlg_restore.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/sys_dlg_restore.png -------------------------------------------------------------------------------- /skin/360SafeRes/vertical_border.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/vertical_border.bmp -------------------------------------------------------------------------------- /skin/qyplayer/btn_play_mode_next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play_mode_next.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_play_mode_rand.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play_mode_rand.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_bg_fix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_bg_fix.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_cache.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_cache.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_thumb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_thumb.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_thumb_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_thumb_1.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_value.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_value.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_value2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_value2.png -------------------------------------------------------------------------------- /skin/qyplayer/song_list_title_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/song_list_title_bg.png -------------------------------------------------------------------------------- /skin/360SafeRes/examine_background.bmp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/360SafeRes/examine_background.bmp -------------------------------------------------------------------------------- /skin/qyplayer/btn_play_mode_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play_mode_circle.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_play_mode_single.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play_mode_single.png -------------------------------------------------------------------------------- /skin/qyplayer/common_scroll_thumb_mask.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/common_scroll_thumb_mask.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_value2_fix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_value2_fix.png -------------------------------------------------------------------------------- /skin/qyplayer/song_list_title_btn_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/song_list_title_btn_bg.png -------------------------------------------------------------------------------- /skin/qyplayer/volume_slider_thumb_mini.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/volume_slider_thumb_mini.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_thumb_animate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_thumb_animate.png -------------------------------------------------------------------------------- /skin/qyplayer/btn_play_mode_single_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/btn_play_mode_single_circle.png -------------------------------------------------------------------------------- /skin/qyplayer/play_slider_thumb_animate_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/play_slider_thumb_animate_1.png -------------------------------------------------------------------------------- /skin/qyplayer/7CA3EE8F40384DC0C6FB2ACF69EE9AD9.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/progmboy/gtkduilib/HEAD/skin/qyplayer/7CA3EE8F40384DC0C6FB2ACF69EE9AD9.jpg -------------------------------------------------------------------------------- /gtkduilib/UIEvent.cpp: -------------------------------------------------------------------------------- 1 | #include "stdafx.h" 2 | #include "UIEvent.h" 3 | 4 | CUIEvent::CUIEvent(void) 5 | { 6 | } 7 | 8 | CUIEvent::~CUIEvent(void) 9 | { 10 | } 11 | -------------------------------------------------------------------------------- /skin/qyplayer/qyplayer.uiproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /gtkduilib/stdafx.cpp: -------------------------------------------------------------------------------- 1 | // stdafx.cpp : source file that includes just the standard includes 2 | // gtkduilib.pch will be the pre-compiled header 3 | // stdafx.obj will contain the pre-compiled type information 4 | 5 | #include "stdafx.h" 6 | 7 | // TODO: reference any additional headers you need in STDAFX.H 8 | // and not in this file 9 | -------------------------------------------------------------------------------- /gtkduilib_test/stdafx.cpp: -------------------------------------------------------------------------------- 1 | // stdafx.cpp : source file that includes just the standard includes 2 | // gtkduilib_test.pch will be the pre-compiled header 3 | // stdafx.obj will contain the pre-compiled type information 4 | 5 | #include "stdafx.h" 6 | 7 | // TODO: reference any additional headers you need in STDAFX.H 8 | // and not in this file 9 | -------------------------------------------------------------------------------- /gtkduilib/stdafx.h: -------------------------------------------------------------------------------- 1 | // stdafx.h : include file for standard system include files, 2 | // or project specific include files that are used frequently, but 3 | // are changed infrequently 4 | // 5 | 6 | #ifndef __STDAFX__H__ 7 | #define __STDAFX__H__ 8 | 9 | #define WIN32_LEAN_AND_MEAN 10 | 11 | #define NOTHING 12 | 13 | #include "UILib.h" 14 | 15 | #endif 16 | 17 | -------------------------------------------------------------------------------- /gtkduilib_test/stdafx.h: -------------------------------------------------------------------------------- 1 | // stdafx.h : include file for standard system include files, 2 | // or project specific include files that are used frequently, but 3 | // are changed infrequently 4 | // 5 | 6 | #pragma once 7 | 8 | //#include "targetver.h" 9 | 10 | #include 11 | 12 | 13 | 14 | // TODO: reference additional headers your program requires here 15 | -------------------------------------------------------------------------------- /gtkduilib.workspace: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /gtkduilib/NotifyPump.h: -------------------------------------------------------------------------------- 1 | #ifndef __NOTIFYPUMP__H__ 2 | #define __NOTIFYPUMP__H__ 3 | 4 | class CNotifyPump 5 | { 6 | public: 7 | CNotifyPump(void); 8 | virtual ~CNotifyPump(void); 9 | public: 10 | bool AddVirtualWnd(CUIString strName, CNotifyPump* pObject); 11 | bool RemoveVirtualWnd(CUIString strName); 12 | void NotifyPump(TNotifyUI& msg); 13 | bool LoopDispatch(TNotifyUI& msg); 14 | DUI_DECLARE_MESSAGE_MAP() 15 | private: 16 | CStdStringPtrMap m_VirtualWndMap; 17 | }; 18 | 19 | #endif 20 | 21 | -------------------------------------------------------------------------------- /skin/qyplayer/music_list.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 9 | 10 | -------------------------------------------------------------------------------- /gtkduilib/UIText.h: -------------------------------------------------------------------------------- 1 | #ifndef __UITEXT_H__ 2 | #define __UITEXT_H__ 3 | 4 | class CUIText : public CUILabel 5 | { 6 | public: 7 | CUIText(); 8 | ~CUIText(); 9 | 10 | CUIString GetClass() const; 11 | UINT GetControlFlags() const; 12 | LPVOID GetInterface(const CUIString& strName); 13 | 14 | CUIString* GetLinkContent(int iIndex); 15 | 16 | void DoEvent(TEventUI& event); 17 | SIZE EstimateSize(SIZE szAvailable); 18 | 19 | void PaintText(cairo_t *cr); 20 | 21 | protected: 22 | enum { MAX_LINK = 8 }; 23 | int m_nLinks; 24 | CUIRect m_rcLinks[MAX_LINK]; 25 | CUIString m_sLinks[MAX_LINK]; 26 | int m_nHoverLink; 27 | }; 28 | 29 | 30 | #endif //__UITEXT_H__ -------------------------------------------------------------------------------- /gtkduilib_test/targetver.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | // The following macros define the minimum required platform. The minimum required platform 4 | // is the earliest version of Windows, Internet Explorer etc. that has the necessary features to run 5 | // your application. The macros work by enabling all features available on platform versions up to and 6 | // including the version specified. 7 | 8 | // Modify the following defines if you have to target a platform prior to the ones specified below. 9 | // Refer to MSDN for the latest info on corresponding values for different platforms. 10 | #ifndef _WIN32_WINNT // Specifies that the minimum required platform is Windows Vista. 11 | #define _WIN32_WINNT 0x0600 // Change this to the appropriate value to target other versions of Windows. 12 | #endif 13 | 14 | -------------------------------------------------------------------------------- /360Demo/360Demo.layout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /qyplayer/qyplayer.layout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /gtkduilib_test/gtkduilib_test.layout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /gtkduilib/DialogBuilder.h: -------------------------------------------------------------------------------- 1 | #ifndef __DIALOGBUILDER__H__ 2 | #define __DIALOGBUILDER__H__ 3 | 4 | #include "pugixml.hpp" 5 | 6 | class IDialogBuilderCallback 7 | { 8 | public: 9 | virtual CUIControl* CreateControl(const CUIString& strClass) = 0; 10 | }; 11 | 12 | class CDialogBuilder 13 | { 14 | public: 15 | CDialogBuilder(void); 16 | CDialogBuilder(IDialogBuilderCallback *callback); 17 | virtual ~CDialogBuilder(void); 18 | 19 | public: 20 | 21 | CUIControl* Create(const CUIString& strXmlPath, CUIWindow* pRootDialog = NULL, CUIControl* pParent = NULL); 22 | void SetCallback(IDialogBuilderCallback* callback); 23 | 24 | private: 25 | CUIControl* Create(CUIWindow* pRootDialog = NULL, CUIControl* pParent = NULL); 26 | CUIControl* ParseControl(pugi::xml_node node, CUIWindow* pRootDialog, CUIControl* pParent); 27 | 28 | private: 29 | IDialogBuilderCallback *m_callBack; 30 | pugi::xml_document m_doc; 31 | }; 32 | 33 | #endif -------------------------------------------------------------------------------- /gtkduilib/UIFont.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "UIRef.h" 4 | #include "UIString.h" 5 | #include "UIUtils.h" 6 | 7 | 8 | class CUIFont: public CRefBase 9 | { 10 | public: 11 | CUIFont(void); 12 | CUIFont(const CUIString& strName, const CUIString& strFaceName, int nSize = 0, BOOL bBold = FALSE, 13 | BOOL bUnderline = FALSE, BOOL bItalic = FALSE); 14 | virtual ~CUIFont(void); 15 | VOID SetItalic(BOOL bItalic); 16 | VOID SetBold(BOOL bBold); 17 | PangoFontDescription* GetHandle(); 18 | PangoFontDescription* Create(); 19 | VOID SetUnderLine(BOOL bUnderline); 20 | VOID SetSize(int nSize); 21 | VOID SetName(const CUIString& strName); 22 | VOID SetFaceName(const CUIString& strFaceName); 23 | VOID ReleaseFont(); 24 | UINT GetFontHeight(); 25 | 26 | private: 27 | 28 | CUIString m_strName; 29 | CUIString m_strFaceName; 30 | int m_nSize; 31 | BOOL m_bBold; 32 | BOOL m_bUnderLine; 33 | BOOL m_bItalic; 34 | PangoFontDescription * m_hFont; 35 | }; 36 | -------------------------------------------------------------------------------- /gtkduilib/UIProgress.h: -------------------------------------------------------------------------------- 1 | #ifndef __UIPROGRESS_H__ 2 | #define __UIPROGRESS_H__ 3 | 4 | class CUIProgress : public CUILabel 5 | { 6 | public: 7 | CUIProgress(); 8 | 9 | CUIString GetClass() const; 10 | LPVOID GetInterface(const CUIString& strName); 11 | 12 | bool IsHorizontal(); 13 | void SetHorizontal(bool bHorizontal = true); 14 | bool IsStretchForeImage(); 15 | void SetStretchForeImage(bool bStretchForeImage = true); 16 | int GetMinValue() const; 17 | void SetMinValue(int nMin); 18 | int GetMaxValue() const; 19 | void SetMaxValue(int nMax); 20 | int GetValue() const; 21 | void SetValue(int nValue); 22 | CUIString GetForeImage() const; 23 | void SetForeImage(const CUIString& strImage); 24 | void SetForePadding(int nPadding); 25 | 26 | void SetAttribute(LPCWSTR pstrName, LPCWSTR pstrValue); 27 | void PaintStatusImage(cairo_t *cr); 28 | int GetForePadding(); 29 | 30 | 31 | protected: 32 | bool m_bHorizontal; 33 | bool m_bStretchForeImage; 34 | int m_nMax; 35 | int m_nMin; 36 | int m_nValue; 37 | int m_nPadding; 38 | 39 | CUIString m_strForeImage; 40 | //CUIString m_sForeImageModify; 41 | }; 42 | 43 | 44 | #endif // __UIPROGRESS_H__ 45 | -------------------------------------------------------------------------------- /gtkduilib/UILib.h: -------------------------------------------------------------------------------- 1 | #ifndef __UILIB__H__ 2 | #define __UILIB__H__ 3 | 4 | #include 5 | #include 6 | #include 7 | #include 8 | 9 | #ifdef WIN32 10 | #include 11 | #else 12 | #include "compat.h" 13 | #endif 14 | 15 | #include 16 | //#include 17 | //#include 18 | //#include 19 | 20 | 21 | #include "UIUtils.h" 22 | #include "UIString.h" 23 | #include "UIDefine.h" 24 | #include "NotifyPump.h" 25 | #include "UIFont.h" 26 | #include "UIEvent.h" 27 | #include "UIRender.h" 28 | #include "ResourceMgr.h" 29 | #include "UIControl.h" 30 | #include "UILabel.h" 31 | #include "UIButton.h" 32 | #include "UIText.h" 33 | #include "UIOption.h" 34 | #include "UIProgress.h" 35 | #include "UISlider.h" 36 | #include "UIScrollBar.h" 37 | #include "UIWindow.h" 38 | 39 | #include "UIContainer.h" 40 | #include "UIHorizontalLayout.h" 41 | #include "UIVerticalLayout.h" 42 | #include "UITabLayout.h" 43 | #include "UITileLayout.h" 44 | #include "DialogBuilder.h" 45 | #include "UIChildLayout.h" 46 | 47 | #include "UIList.h" 48 | 49 | #include "WindowImpBase.h" 50 | 51 | #endif -------------------------------------------------------------------------------- /gtkduilib/UILabel.h: -------------------------------------------------------------------------------- 1 | #ifndef __UILABEL_H__ 2 | #define __UILABEL_H__ 3 | 4 | //#pragma once 5 | 6 | class CUILabel : public CUIControl 7 | { 8 | public: 9 | CUILabel(); 10 | 11 | CUIString GetClass() const; 12 | LPVOID GetInterface(const CUIString& strName); 13 | 14 | void SetTextStyle(UINT uStyle); 15 | UINT GetTextStyle() const; 16 | void SetTextColor(DWORD dwTextColor); 17 | DWORD GetTextColor() const; 18 | void SetDisabledTextColor(DWORD dwTextColor); 19 | DWORD GetDisabledTextColor() const; 20 | void SetFont(const CUIString &strFontName); 21 | CUIString GetFont() const; 22 | CUIRect GetTextPadding() const; 23 | void SetTextPadding(const CUIRect& rc); 24 | bool IsShowHtml(); 25 | void SetShowHtml(bool bShowHtml = true); 26 | 27 | SIZE EstimateSize(SIZE szAvailable); 28 | void DoEvent(TEventUI& event); 29 | void SetAttribute(LPCWSTR pstrName, LPCWSTR pstrValue); 30 | 31 | void PaintText(cairo_t *cr); 32 | 33 | protected: 34 | DWORD m_dwTextColor; 35 | DWORD m_dwDisabledTextColor; 36 | CUIString m_strFontName; 37 | UINT m_uTextStyle; 38 | CUIRect m_rcTextPadding; 39 | bool m_bShowHtml; 40 | }; 41 | 42 | #endif // __UILABEL_H__ -------------------------------------------------------------------------------- /gtkduilib/ReadMe.txt: -------------------------------------------------------------------------------- 1 | ======================================================================== 2 | STATIC LIBRARY : gtkduilib Project Overview 3 | ======================================================================== 4 | 5 | AppWizard has created this gtkduilib library project for you. 6 | 7 | This file contains a summary of what you will find in each of the files that 8 | make up your gtkduilib application. 9 | 10 | 11 | gtkduilib.vcproj 12 | This is the main project file for VC++ projects generated using an Application Wizard. 13 | It contains information about the version of Visual C++ that generated the file, and 14 | information about the platforms, configurations, and project features selected with the 15 | Application Wizard. 16 | 17 | 18 | ///////////////////////////////////////////////////////////////////////////// 19 | 20 | StdAfx.h, StdAfx.cpp 21 | These files are used to build a precompiled header (PCH) file 22 | named gtkduilib.pch and a precompiled types file named StdAfx.obj. 23 | 24 | ///////////////////////////////////////////////////////////////////////////// 25 | Other notes: 26 | 27 | AppWizard uses "TODO:" comments to indicate parts of the source code you 28 | should add to or customize. 29 | 30 | ///////////////////////////////////////////////////////////////////////////// 31 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # gtkduilib 2 | 3 | duilib向gtk的移植 4 | 5 | ## 编译 6 | 7 | windows: 8 | ``` 9 | install [msys2](https://msys2.github.io/) 10 | then install gtk3.0.x from msys2 shell 11 | install codeblocks 12 | open the workspace and build 13 | ``` 14 | 15 | linux (ubuntu): 16 | ``` 17 | sudo apt-get install codebloks libgtk3.0xxxx 18 | open the workspace and build 19 | ``` 20 | 21 | ## Demo 22 | 大家可以看下demo. 23 | 24 | player run in windows: 25 | 26 | ![player_windows](https://github.com/progmboy/gtkduilib/raw/master/snapshots/1.png) 27 | 28 | player run in ubuntu: 29 | 30 | ![player_ubuntu](https://github.com/progmboy/gtkduilib/raw/master/snapshots/2.jpg) 31 | 32 | 360safe run in ubuntu: 33 | 34 | ![360demo](https://github.com/progmboy/gtkduilib/raw/master/snapshots/3.jpg) 35 | 36 | ## 和原版的duilib有啥不同 37 | 基本上兼容原版duilib的格式,主要有下面几种不同. 38 | 39 | 1. 全部使用unicode, 便于移植, windows A/W很是闹心呀. 40 | 2. 绘制字体使用pango的接口,没有保留原版的绘制接口. 41 | 3. 好多LPCTSTR类型的参数使用const CUIString& 传递. 42 | 4. 使用pugixml作为xml解析. 43 | 5. 直接使用gdk-pixbuf加载图片 44 | 45 | ## 备注 46 | 1. 做这个的目的其实是为了学习下gtk.duilib的框架很好,把windows消息机制移植到gtk的机制,控件代码基本上都不用改。 47 | 2. gtk for windows的bug多多,建议还是在linux下弄 48 | 3. gtk 在windows下是支持加载系统字体的,但是只支持english name, 大家写xml的时候注意下。 49 | 4. 不喜勿喷, 谢谢 ^_^ 50 | 5. 欢迎pull request 51 | 52 | ## TODO: 53 | 太多了。 54 | - [ ] 上传demo 55 | - [ ] 键盘事件 56 | - [ ] EDIT控件,树控件, webview 57 | - [ ] 移植原版demo 58 | - [ ] ... 59 | -------------------------------------------------------------------------------- /gtkduilib/UISlider.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef __UISLIDER_H__ 3 | #define __UISLIDER_H__ 4 | 5 | class CUISlider : public CUIProgress 6 | { 7 | public: 8 | CUISlider(); 9 | CUIString GetClass() const; 10 | UINT GetControlFlags() const; 11 | LPVOID GetInterface(const CUIString& strName); 12 | 13 | void SetEnabled(bool bEnable = true); 14 | 15 | int GetChangeStep(); 16 | void SetChangeStep(int step); 17 | void SetThumbSize(SIZE szXY); 18 | CUIRect GetThumbRect() const; 19 | CUIString GetThumbImage() const; 20 | void SetThumbImage(const CUIString& strImage); 21 | CUIString GetThumbHotImage() const; 22 | void SetThumbHotImage(const CUIString& strImage); 23 | CUIString GetThumbPushedImage() const; 24 | void SetThumbPushedImage(const CUIString& strImage); 25 | 26 | void SetValue(int nValue); 27 | void DoEvent(TEventUI& event); 28 | void SetAttribute(LPCWSTR pstrName, LPCWSTR pstrValue); 29 | void PaintStatusImage(cairo_t *cr); 30 | void SetVisible(bool bVisible /* = true */); 31 | void SetSendMove(bool bSendMove); 32 | bool IsSendMove(); 33 | protected: 34 | CUISize m_szThumb; 35 | UINT m_uButtonState; 36 | int m_nStep; 37 | 38 | CUIString m_sThumbImage; 39 | CUIString m_sThumbHotImage; 40 | CUIString m_sThumbPushedImage; 41 | 42 | CUIString m_sImageModify; 43 | bool m_bDelyInVisible; 44 | int m_nDownValue; 45 | bool m_bSendMove; 46 | }; 47 | 48 | #endif // __UISLIDER_H__ -------------------------------------------------------------------------------- /gtkduilib_test/ReadMe.txt: -------------------------------------------------------------------------------- 1 | ======================================================================== 2 | CONSOLE APPLICATION : gtkduilib_test Project Overview 3 | ======================================================================== 4 | 5 | AppWizard has created this gtkduilib_test application for you. 6 | 7 | This file contains a summary of what you will find in each of the files that 8 | make up your gtkduilib_test application. 9 | 10 | 11 | gtkduilib_test.vcproj 12 | This is the main project file for VC++ projects generated using an Application Wizard. 13 | It contains information about the version of Visual C++ that generated the file, and 14 | information about the platforms, configurations, and project features selected with the 15 | Application Wizard. 16 | 17 | gtkduilib_test.cpp 18 | This is the main application source file. 19 | 20 | ///////////////////////////////////////////////////////////////////////////// 21 | Other standard files: 22 | 23 | StdAfx.h, StdAfx.cpp 24 | These files are used to build a precompiled header (PCH) file 25 | named gtkduilib_test.pch and a precompiled types file named StdAfx.obj. 26 | 27 | ///////////////////////////////////////////////////////////////////////////// 28 | Other notes: 29 | 30 | AppWizard uses "TODO:" comments to indicate parts of the source code you 31 | should add to or customize. 32 | 33 | ///////////////////////////////////////////////////////////////////////////// 34 | -------------------------------------------------------------------------------- /360Demo/360Demo.cbp: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 47 | 48 | -------------------------------------------------------------------------------- /qyplayer/qyplayer.cbp: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 47 | 48 | -------------------------------------------------------------------------------- /gtkduilib/UIEvent.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | enum EVENTTYPE_UI 4 | { 5 | UIEVENT__FIRST = 1, 6 | UIEVENT__KEYBEGIN, 7 | UIEVENT_KEYDOWN, 8 | UIEVENT_KEYUP, 9 | UIEVENT_CHAR, 10 | UIEVENT_SYSKEY, 11 | UIEVENT__KEYEND, 12 | UIEVENT__MOUSEBEGIN, 13 | UIEVENT_MOUSEMOVE, 14 | UIEVENT_MOUSELEAVE, 15 | UIEVENT_MOUSEENTER, 16 | UIEVENT_MOUSEHOVER, 17 | UIEVENT_BUTTONDOWN, 18 | UIEVENT_BUTTONUP, 19 | UIEVENT_RBUTTONDOWN, 20 | UIEVENT_DBLCLICK, 21 | UIEVENT_CONTEXTMENU, 22 | UIEVENT_SCROLLWHEEL, 23 | UIEVENT__MOUSEEND, 24 | UIEVENT_KILLFOCUS, 25 | UIEVENT_SETFOCUS, 26 | UIEVENT_WINDOWSIZE, 27 | UIEVENT_SETCURSOR, 28 | UIEVENT_TIMER, 29 | UIEVENT_NOTIFY, 30 | UIEVENT_COMMAND, 31 | UIEVENT__LAST, 32 | }; 33 | 34 | #define IS_MOUSE_EVENT(_type) (_type > UIEVENT__MOUSEBEGIN && _type < UIEVENT__MOUSEEND) 35 | 36 | class CUIControl; 37 | 38 | typedef struct tagTEventUI 39 | { 40 | int Type; 41 | CUIControl* pSender; 42 | DWORD dwTimestamp; 43 | POINT ptMouse; 44 | WCHAR chKey; 45 | WORD wKeyState; 46 | WPARAM wParam; 47 | LPARAM lParam; 48 | } TEventUI; 49 | 50 | class CUIEvent 51 | { 52 | public: 53 | CUIEvent(void); 54 | CUIEvent(PVOID Sender, DWORD dwType, DWORD dwTime); 55 | CUIEvent(GdkEvent *Event); 56 | virtual ~CUIEvent(void); 57 | 58 | private: 59 | DWORD m_Type; 60 | PVOID m_Sender; 61 | DWORD m_Time; 62 | 63 | }; 64 | -------------------------------------------------------------------------------- /gtkduilib.workspace.layout: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /gtkduilib.sln: -------------------------------------------------------------------------------- 1 | 2 | Microsoft Visual Studio Solution File, Format Version 10.00 3 | # Visual Studio 2008 4 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gtkduilib", "gtkduilib\gtkduilib.vcproj", "{245726C5-62B3-4978-95BC-678DB6A8CA0D}" 5 | EndProject 6 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "gtkduilib_test", "gtkduilib_test\gtkduilib_test.vcproj", "{D496C7CB-54B6-4E70-AAD1-910D338840A9}" 7 | ProjectSection(ProjectDependencies) = postProject 8 | {245726C5-62B3-4978-95BC-678DB6A8CA0D} = {245726C5-62B3-4978-95BC-678DB6A8CA0D} 9 | EndProjectSection 10 | EndProject 11 | Global 12 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 13 | Debug|Win32 = Debug|Win32 14 | Release|Win32 = Release|Win32 15 | EndGlobalSection 16 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 17 | {245726C5-62B3-4978-95BC-678DB6A8CA0D}.Debug|Win32.ActiveCfg = Debug|Win32 18 | {245726C5-62B3-4978-95BC-678DB6A8CA0D}.Debug|Win32.Build.0 = Debug|Win32 19 | {245726C5-62B3-4978-95BC-678DB6A8CA0D}.Release|Win32.ActiveCfg = Release|Win32 20 | {245726C5-62B3-4978-95BC-678DB6A8CA0D}.Release|Win32.Build.0 = Release|Win32 21 | {D496C7CB-54B6-4E70-AAD1-910D338840A9}.Debug|Win32.ActiveCfg = Debug|Win32 22 | {D496C7CB-54B6-4E70-AAD1-910D338840A9}.Debug|Win32.Build.0 = Debug|Win32 23 | {D496C7CB-54B6-4E70-AAD1-910D338840A9}.Release|Win32.ActiveCfg = Release|Win32 24 | {D496C7CB-54B6-4E70-AAD1-910D338840A9}.Release|Win32.Build.0 = Release|Win32 25 | EndGlobalSection 26 | GlobalSection(SolutionProperties) = preSolution 27 | HideSolutionNode = FALSE 28 | EndGlobalSection 29 | EndGlobal 30 | -------------------------------------------------------------------------------- /gtkduilib/UIOption.h: -------------------------------------------------------------------------------- 1 | #ifndef __UIOPTION_H__ 2 | #define __UIOPTION_H__ 3 | 4 | class CUIOption : public CUIButton 5 | { 6 | public: 7 | CUIOption(); 8 | ~CUIOption(); 9 | 10 | CUIString GetClass() const; 11 | LPVOID GetInterface(const CUIString& strName); 12 | 13 | //void SetManager(CPaintManagerUI* pManager, CControlUI* pParent, bool bInit = true); 14 | 15 | bool Activate(); 16 | void SetEnabled(bool bEnable = true); 17 | 18 | CUIString GetSelectedImage(); 19 | void SetSelectedImage(const CUIString& strImage); 20 | 21 | CUIString GetSelectedHotImage(); 22 | void SetSelectedHotImage(const CUIString& strImage); 23 | 24 | void SetSelectedTextColor(DWORD dwTextColor); 25 | DWORD GetSelectedTextColor(); 26 | 27 | void SetSelectedBkColor(DWORD dwBkColor); 28 | DWORD GetSelectBkColor(); 29 | 30 | CUIString GetForeImage(); 31 | void SetForeImage(const CUIString& strImage); 32 | 33 | CUIString GetGroup() const; 34 | void SetGroup(const CUIString& strImage); 35 | bool IsSelected() const; 36 | virtual void Selected(bool bSelected); 37 | 38 | SIZE EstimateSize(SIZE szAvailable); 39 | void SetAttribute(LPCWSTR pstrName, LPCWSTR pstrValue); 40 | 41 | void PaintStatusImage(cairo_t *cr); 42 | void PaintText(cairo_t *cr); 43 | void SetOwnWindow(CUIWindow* pWindow, CUIControl* pParent, bool bInit); 44 | 45 | protected: 46 | bool m_bSelected; 47 | CUIString m_sGroupName; 48 | 49 | DWORD m_dwSelectedBkColor; 50 | DWORD m_dwSelectedTextColor; 51 | 52 | CUIString m_sSelectedImage; 53 | CUIString m_sSelectedHotImage; 54 | CUIString m_sForeImage; 55 | }; 56 | 57 | 58 | #endif // __UIOPTION_H__ -------------------------------------------------------------------------------- /gtkduilib/UIChildLayout.cpp: -------------------------------------------------------------------------------- 1 | #include "stdafx.h" 2 | #include "UIChildLayout.h" 3 | 4 | CUIChildLayout::CUIChildLayout():m_Callback(NULL) 5 | { 6 | 7 | } 8 | 9 | void CUIChildLayout::Init() 10 | { 11 | if (!m_pstrXMLFile.IsEmpty()){ 12 | 13 | // 14 | // TODO CDialogBuilder 15 | // 16 | 17 | CDialogBuilder builder; 18 | CUIContainer* pChildWindow = static_cast(builder.Create(m_pstrXMLFile.GetData(), m_Window, NULL)); 19 | if (pChildWindow){ 20 | this->Add(pChildWindow); 21 | }else{ 22 | this->RemoveAll(); 23 | } 24 | 25 | // 26 | // set callback to NULL 27 | // 28 | 29 | if (!m_Callback){ 30 | m_Callback = NULL; 31 | } 32 | } 33 | } 34 | 35 | void CUIChildLayout::SetAttribute( LPCWSTR pstrName, LPCWSTR pstrValue ) 36 | { 37 | if(wcscmp(pstrName, L"xmlfile") == 0) 38 | SetChildLayoutXML(pstrValue); 39 | else 40 | CUIContainer::SetAttribute(pstrName,pstrValue); 41 | } 42 | 43 | void CUIChildLayout::SetChildLayoutXML(const CUIString& strXML) 44 | { 45 | m_pstrXMLFile = strXML; 46 | } 47 | 48 | CUIString CUIChildLayout::GetChildLayoutXML() 49 | { 50 | return m_pstrXMLFile; 51 | } 52 | 53 | LPVOID CUIChildLayout::GetInterface(const CUIString& strName) 54 | { 55 | if(strName == DUI_CTR_CHILDLAYOUT) 56 | return static_cast(this); 57 | return CUIControl::GetInterface(strName); 58 | } 59 | 60 | CUIString CUIChildLayout::GetClass() const 61 | { 62 | return L"ChildLayoutUI"; 63 | } 64 | 65 | 66 | VOID CUIChildLayout::SetBuilderCallback(IDialogBuilderCallback* pCallback) 67 | { 68 | m_Callback = pCallback; 69 | } 70 | 71 | -------------------------------------------------------------------------------- /gtkduilib_test/gtkduilib_test.cbp: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 54 | 55 | -------------------------------------------------------------------------------- /gtkduilib/UIButton.h: -------------------------------------------------------------------------------- 1 | #ifndef __UIBUTTON_H__ 2 | #define __UIBUTTON_H__ 3 | 4 | class CUIButton : public CUILabel 5 | { 6 | public: 7 | CUIButton(); 8 | 9 | CUIString GetClass() const; 10 | LPVOID GetInterface(const CUIString& strName); 11 | UINT GetControlFlags() const; 12 | 13 | bool Activate(); 14 | void SetEnabled(bool bEnable = true); 15 | void DoEvent(TEventUI& event); 16 | 17 | LPCWSTR GetNormalImage(); 18 | void SetNormalImage(LPCWSTR pStrImage); 19 | LPCWSTR GetHotImage(); 20 | void SetHotImage(LPCWSTR pStrImage); 21 | LPCWSTR GetPushedImage(); 22 | void SetPushedImage(LPCWSTR pStrImage); 23 | LPCWSTR GetFocusedImage(); 24 | void SetFocusedImage(LPCWSTR pStrImage); 25 | LPCWSTR GetDisabledImage(); 26 | void SetDisabledImage(LPCWSTR pStrImage); 27 | LPCWSTR GetForeImage(); 28 | void SetForeImage(LPCWSTR pStrImage); 29 | LPCWSTR GetHotForeImage(); 30 | void SetHotForeImage(LPCWSTR pStrImage); 31 | 32 | void SetHotBkColor(DWORD dwColor); 33 | DWORD GetHotBkColor() const; 34 | void SetHotTextColor(DWORD dwColor); 35 | DWORD GetHotTextColor() const; 36 | void SetPushedTextColor(DWORD dwColor); 37 | DWORD GetPushedTextColor() const; 38 | void SetFocusedTextColor(DWORD dwColor); 39 | DWORD GetFocusedTextColor() const; 40 | SIZE EstimateSize(SIZE szAvailable); 41 | void SetAttribute(LPCWSTR pstrName, LPCWSTR pstrValue); 42 | 43 | void PaintText(cairo_t *cr); 44 | void PaintStatusImage(cairo_t *cr); 45 | 46 | protected: 47 | UINT m_uButtonState; 48 | 49 | DWORD m_dwHotBkColor; 50 | DWORD m_dwHotTextColor; 51 | DWORD m_dwPushedTextColor; 52 | DWORD m_dwFocusedTextColor; 53 | 54 | CUIString m_sNormalImage; 55 | CUIString m_sHotImage; 56 | CUIString m_sHotForeImage; 57 | CUIString m_sPushedImage; 58 | CUIString m_sPushedForeImage; 59 | CUIString m_sFocusedImage; 60 | CUIString m_sDisabledImage; 61 | CUIString m_sForeImage; 62 | }; 63 | 64 | 65 | #endif // __UIBUTTON_H__ -------------------------------------------------------------------------------- /gtkduilib/UIRef.h: -------------------------------------------------------------------------------- 1 | #ifndef __DUI_REF_H__ 2 | #define __DUI_REF_H__ 3 | 4 | //#include "DUIDef.h" 5 | 6 | //T's base class for CRefPtr 7 | class CRefBase 8 | { 9 | public: 10 | CRefBase() 11 | { 12 | m_nRefCount = 0; 13 | } 14 | 15 | int GetRef() const 16 | { 17 | return m_nRefCount; 18 | } 19 | 20 | int AddRef() 21 | { 22 | return ++m_nRefCount; 23 | } 24 | 25 | int Release() 26 | { 27 | if(!--m_nRefCount){ 28 | delete this; 29 | } 30 | return m_nRefCount; 31 | } 32 | 33 | VOID Reset() 34 | { 35 | m_nRefCount = 0; 36 | } 37 | 38 | 39 | private: 40 | int m_nRefCount; 41 | }; 42 | 43 | template 44 | class CRefPtr 45 | { 46 | public: 47 | T* operator->() const 48 | { 49 | return m_pRawObj; 50 | } 51 | 52 | T& operator()() const 53 | { 54 | return *m_pRawObj; 55 | } 56 | 57 | T& operator*() const 58 | { 59 | return *m_pRawObj; 60 | } 61 | 62 | T* GetPtr() const 63 | { 64 | return m_pRawObj; 65 | } 66 | 67 | bool IsNull() const 68 | { 69 | return m_pRawObj == NULL; 70 | } 71 | 72 | CRefPtr() 73 | { 74 | m_pRawObj = NULL; 75 | } 76 | 77 | CRefPtr(T* p) 78 | { 79 | m_pRawObj = p; 80 | if(p != NULL) 81 | { 82 | p->AddRef(); 83 | } 84 | } 85 | 86 | CRefPtr(const CRefPtr& ref) 87 | { 88 | m_pRawObj = ref.m_pRawObj; 89 | if(m_pRawObj != NULL) 90 | { 91 | m_pRawObj->AddRef(); 92 | } 93 | } 94 | 95 | ~CRefPtr() 96 | { 97 | if(m_pRawObj != NULL){ 98 | m_pRawObj->Release(); 99 | } 100 | } 101 | 102 | CRefPtr& operator = (const CRefPtr& ref) 103 | { 104 | if(this != &ref) 105 | { 106 | if(m_pRawObj != NULL){ 107 | m_pRawObj->Release(); 108 | } 109 | 110 | m_pRawObj = ref.m_pRawObj; 111 | 112 | if(m_pRawObj != NULL){ 113 | m_pRawObj->AddRef(); 114 | } 115 | } 116 | 117 | return *this; 118 | } 119 | 120 | bool operator == (const CRefPtr& ref) const 121 | { 122 | return m_pRawObj == ref.m_pRawObj; 123 | } 124 | 125 | bool operator != (const CRefPtr& ref) const 126 | { 127 | return m_pRawObj != ref.m_pRawObj; 128 | } 129 | 130 | private: 131 | T* m_pRawObj; 132 | }; 133 | 134 | #endif //__DUI_REF_H__ 135 | -------------------------------------------------------------------------------- /gtkduilib/UIRender.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #define UIGetAValue(rgb) (LOBYTE((rgb)>>24)) 4 | #define UIGetBValue(rgb) (LOBYTE(rgb)) 5 | #define UIGetGValue(rgb) (LOBYTE(((WORD)(rgb)) >> 8)) 6 | #define UIGetRValue(rgb) (LOBYTE((rgb)>>16)) 7 | 8 | class CUIRender 9 | { 10 | public: 11 | CUIRender(void); 12 | virtual ~CUIRender(void); 13 | public: 14 | static void DrawLinerGradient(cairo_t * cr, int x, int y, int nWidth, 15 | int nHeight, DWORD dwFirst, DWORD dwSecond, 16 | BOOL bVertial, int nSteps ); 17 | static void DrawLinerGradient( cairo_t * cr, const CUIRect &rc, DWORD dwFirst, 18 | DWORD dwSecond, BOOL bVertial, int nSteps ); 19 | static void DrawColor(cairo_t *cr, int x, int y, int nWidth, int nHeight, DWORD dwColor); 20 | static void DrawColor(cairo_t *cr, const CUIRect& rc, DWORD dwColor); 21 | static void DrawRect(cairo_t* cr, const CUIRect& rc, int nSize, DWORD dwColor); 22 | static bool DrawImage( cairo_t* cr, GdkPixbuf* Pixbuf, const CUIRect& rc, 23 | const CUIRect& rcPaint, const CUIRect& rcImage, const CUIRect& rcCorners, 24 | int alpha, BOOL hole, BOOL xtiled, BOOL ytiled); 25 | static bool DrawImage(cairo_t* cr, /*CUIManager* pManager,*/ const CUIString& strImage, 26 | const CUIRect& rcControl, const CUIRect& rcPaint, const CUIRect& rcDest, 27 | CUIRect& rcImage, const CUIRect& rcCorners, 28 | int alpha, BOOL hole, BOOL xtiled, BOOL ytiled); 29 | static bool AlphaBlend(cairo_t* cr, GdkPixbuf *sPixbuf, int dx, int dy, int dWidth, 30 | int dHeight, int sx, int sy, int sWidth, int sHeight, int alpha); 31 | static bool DrawImageString(cairo_t *cr, /*CUIManager* pManager,*/ const CUIRect& rcControl, 32 | const CUIRect& rcPaint, LPCWSTR lpStrImage, LPCWSTR lpStrModify); 33 | static void DrawText(cairo_t * cr, int x, int y, int nWidth, int nHeight, 34 | LPCWSTR lpszText, DWORD dwStyle, LPCWSTR lpszFontName, DWORD dwColor, bool bShowHtml = false, 35 | CUIRect *rcOut = NULL); 36 | static void DrawText(cairo_t * cr, const CUIRect& rc, const CUIString& strText, 37 | DWORD dwStyle, const CUIString& strFontName, DWORD dwColor, 38 | bool bShowHtml = false, CUIRect *rcOut = NULL); 39 | static void DrawLine(cairo_t *cr, const CUIRect& rc, int nSize, DWORD dwPenColor,int nStyle /*= PS_SOLID*/); 40 | }; -------------------------------------------------------------------------------- /gtkduilib/UIFont.cpp: -------------------------------------------------------------------------------- 1 | #include "stdafx.h" 2 | 3 | #include "UIFont.h" 4 | 5 | CUIFont::CUIFont(void):m_bBold(FALSE), 6 | m_bUnderLine(FALSE), m_bItalic(FALSE), m_hFont(NULL), m_nSize(8) 7 | { 8 | 9 | } 10 | 11 | 12 | CUIFont::CUIFont(const CUIString& strName, const CUIString& strFaceName, 13 | int nSize, BOOL bBold, BOOL bUnderline, BOOL bItalic) 14 | { 15 | m_nSize = nSize * PANGO_SCALE; 16 | m_strName = strName; 17 | m_strFaceName = strFaceName; 18 | m_bBold = bBold; 19 | m_bUnderLine = bUnderline; 20 | m_bItalic = bItalic; 21 | m_hFont = NULL; 22 | } 23 | 24 | CUIFont::~CUIFont(void) 25 | { 26 | ReleaseFont(); 27 | } 28 | 29 | 30 | PangoFontDescription* CUIFont::Create() 31 | { 32 | 33 | // 34 | // create a new desc 35 | // 36 | 37 | PangoFontDescription *desc = pango_font_description_new(); 38 | 39 | // 40 | // set font attribute 41 | // 42 | 43 | if (!m_strFaceName.IsEmpty()){ 44 | pango_font_description_set_family(desc, (LPCSTR)CW2U8(m_strFaceName.GetData())); 45 | } 46 | 47 | // 48 | // set font size 49 | // 50 | 51 | if (m_nSize){ 52 | pango_font_description_set_size(desc, m_nSize); 53 | } 54 | 55 | // 56 | // set Italic 57 | // 58 | 59 | if (m_bItalic){ 60 | pango_font_description_set_style(desc, PANGO_STYLE_ITALIC); 61 | }else{ 62 | pango_font_description_set_style(desc, PANGO_STYLE_NORMAL); 63 | } 64 | 65 | // 66 | // set bold 67 | // 68 | 69 | if (m_bBold){ 70 | pango_font_description_set_weight(desc, PANGO_WEIGHT_BOLD); 71 | }else{ 72 | pango_font_description_set_weight(desc, PANGO_WEIGHT_NORMAL); 73 | } 74 | 75 | m_hFont = desc; 76 | 77 | return m_hFont; 78 | 79 | } 80 | 81 | VOID CUIFont::SetItalic(BOOL bItalic) 82 | { 83 | m_bItalic = bItalic; 84 | } 85 | 86 | VOID CUIFont::SetBold(BOOL bBold) 87 | { 88 | m_bBold = bBold; 89 | } 90 | 91 | VOID CUIFont::SetUnderLine(BOOL bUnderline) 92 | { 93 | m_bUnderLine = bUnderline; 94 | } 95 | 96 | VOID CUIFont::SetSize(int nSize) 97 | { 98 | m_nSize = nSize; 99 | } 100 | 101 | VOID CUIFont::SetName(const CUIString& strName) 102 | { 103 | m_strName = strName; 104 | } 105 | 106 | VOID CUIFont::SetFaceName(const CUIString& strFaceName) 107 | { 108 | m_strFaceName = strFaceName; 109 | } 110 | 111 | PangoFontDescription * CUIFont::GetHandle() 112 | { 113 | return m_hFont; 114 | } 115 | 116 | VOID CUIFont::ReleaseFont() 117 | { 118 | if (m_hFont){ 119 | pango_font_description_free(m_hFont); 120 | m_hFont = NULL; 121 | } 122 | } 123 | 124 | UINT CUIFont::GetFontHeight() 125 | { 126 | if (m_hFont){ 127 | return pango_font_description_get_size(m_hFont) / PANGO_SCALE; 128 | } 129 | return 0; 130 | } 131 | -------------------------------------------------------------------------------- /gtkduilib/UIUtils.h: -------------------------------------------------------------------------------- 1 | #ifndef __INCLUDE_UIUTILS__H__ 2 | #define __INCLUDE_UIUTILS__H__ 3 | 4 | #include 5 | #include "UIString.h" 6 | 7 | BOOL UIIntersectRect( 8 | LPRECT prcDst, 9 | CONST RECT *prcSrc1, 10 | CONST RECT *prcSrc2); 11 | ULONG UIGetTickCount(); 12 | 13 | 14 | class CUIRect : public tagRECT 15 | { 16 | public: 17 | CUIRect(); 18 | CUIRect(const RECT& src); 19 | CUIRect(int iLeft, int iTop, int iRight, int iBottom); 20 | CUIRect(const GdkRectangle& src); 21 | int GetWidth() const; 22 | int GetHeight() const; 23 | void Empty(); 24 | bool IsEmpty(); 25 | bool IsNull() const; 26 | void Join(const RECT& rc); 27 | void ResetOffset(); 28 | void Normalize(); 29 | void Offset(int cx, int cy); 30 | void Inflate(int cx, int cy); 31 | void Deflate(int cx, int cy); 32 | void Union(CUIRect& rc); 33 | bool IsPtIn(POINT pt); 34 | }; 35 | 36 | class CUISize : public tagSIZE 37 | { 38 | public: 39 | CUISize(); 40 | CUISize(const SIZE& src); 41 | CUISize(const RECT rc); 42 | CUISize(int cx, int cy); 43 | bool IsNull() const; 44 | }; 45 | 46 | struct TITEM 47 | { 48 | CUIString Key; 49 | LPVOID Data; 50 | struct TITEM* pPrev; 51 | struct TITEM* pNext; 52 | }; 53 | 54 | class CStdStringPtrMap 55 | { 56 | public: 57 | CStdStringPtrMap(int nSize = 100); 58 | ~CStdStringPtrMap(); 59 | 60 | void Resize(int nSize = 100); 61 | LPVOID Find(LPCWSTR key, bool optimize = true) const; 62 | bool Insert(LPCWSTR key, LPVOID pData); 63 | LPVOID Set(LPCWSTR key, LPVOID pData); 64 | bool Remove(LPCWSTR key); 65 | void RemoveAll(); 66 | int GetSize() const; 67 | LPCWSTR GetAt(int iIndex) const; 68 | LPCWSTR operator[] (int nIndex) const; 69 | 70 | protected: 71 | TITEM** m_aT; 72 | int m_nBuckets; 73 | int m_nCount; 74 | }; 75 | 76 | class CStdPtrArray 77 | { 78 | public: 79 | CStdPtrArray(int iPreallocSize = 0); 80 | CStdPtrArray(const CStdPtrArray& src); 81 | ~CStdPtrArray(); 82 | 83 | void Empty(); 84 | void Resize(int iSize); 85 | bool IsEmpty() const; 86 | int Find(LPVOID iIndex) const; 87 | bool Add(LPVOID pData); 88 | bool SetAt(int iIndex, LPVOID pData); 89 | bool InsertAt(int iIndex, LPVOID pData); 90 | bool Remove(int iIndex); 91 | int GetSize() const; 92 | LPVOID* GetData(); 93 | 94 | LPVOID GetAt(int iIndex) const; 95 | LPVOID operator[] (int nIndex) const; 96 | 97 | protected: 98 | LPVOID* m_ppVoid; 99 | int m_nCount; 100 | int m_nAllocated; 101 | }; 102 | bool ParseRectString(LPCWSTR lpszRect, CUIRect& rc); 103 | bool ParseColorString(LPCWSTR lpszClolor, DWORD &dwColor); 104 | bool ParseBoolString(LPCWSTR lpszBool, bool& bValue); 105 | bool ParseSizeString(LPCWSTR lpszSize, CUISize& Size); 106 | #endif -------------------------------------------------------------------------------- /gtkduilib/pugiconfig.hpp: -------------------------------------------------------------------------------- 1 | /** 2 | * pugixml parser - version 1.6 3 | * -------------------------------------------------------- 4 | * Copyright (C) 2006-2015, by Arseny Kapoulkine (arseny.kapoulkine@gmail.com) 5 | * Report bugs and download new versions at http://pugixml.org/ 6 | * 7 | * This library is distributed under the MIT License. See notice at the end 8 | * of this file. 9 | * 10 | * This work is based on the pugxml parser, which is: 11 | * Copyright (C) 2003, by Kristen Wegner (kristen@tima.net) 12 | */ 13 | 14 | #ifndef HEADER_PUGICONFIG_HPP 15 | #define HEADER_PUGICONFIG_HPP 16 | 17 | // Uncomment this to enable wchar_t mode 18 | #define PUGIXML_WCHAR_MODE 19 | 20 | // Uncomment this to disable XPath 21 | // #define PUGIXML_NO_XPATH 22 | 23 | // Uncomment this to disable STL 24 | // #define PUGIXML_NO_STL 25 | 26 | // Uncomment this to disable exceptions 27 | // #define PUGIXML_NO_EXCEPTIONS 28 | 29 | // Set this to control attributes for public classes/functions, i.e.: 30 | // #define PUGIXML_API __declspec(dllexport) // to export all public symbols from DLL 31 | // #define PUGIXML_CLASS __declspec(dllimport) // to import all classes from DLL 32 | // #define PUGIXML_FUNCTION __fastcall // to set calling conventions to all public functions to fastcall 33 | // In absence of PUGIXML_CLASS/PUGIXML_FUNCTION definitions PUGIXML_API is used instead 34 | 35 | // Tune these constants to adjust memory-related behavior 36 | // #define PUGIXML_MEMORY_PAGE_SIZE 32768 37 | // #define PUGIXML_MEMORY_OUTPUT_STACK 10240 38 | // #define PUGIXML_MEMORY_XPATH_PAGE_SIZE 4096 39 | 40 | // Uncomment this to switch to header-only version 41 | // #define PUGIXML_HEADER_ONLY 42 | 43 | // Uncomment this to enable long long support 44 | // #define PUGIXML_HAS_LONG_LONG 45 | 46 | #endif 47 | 48 | /** 49 | * Copyright (c) 2006-2015 Arseny Kapoulkine 50 | * 51 | * Permission is hereby granted, free of charge, to any person 52 | * obtaining a copy of this software and associated documentation 53 | * files (the "Software"), to deal in the Software without 54 | * restriction, including without limitation the rights to use, 55 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 56 | * copies of the Software, and to permit persons to whom the 57 | * Software is furnished to do so, subject to the following 58 | * conditions: 59 | * 60 | * The above copyright notice and this permission notice shall be 61 | * included in all copies or substantial portions of the Software. 62 | * 63 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 64 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 65 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 66 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 67 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 68 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 69 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 70 | * OTHER DEALINGS IN THE SOFTWARE. 71 | */ 72 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | 4 | # User-specific files 5 | *.suo 6 | *.user 7 | *.userosscache 8 | *.sln.docstates 9 | 10 | # User-specific files (MonoDevelop/Xamarin Studio) 11 | *.userprefs 12 | 13 | # Build results 14 | [Dd]ebug/ 15 | [Dd]ebugPublic/ 16 | [Rr]elease/ 17 | [Rr]eleases/ 18 | x64/ 19 | x86/ 20 | build/ 21 | bld/ 22 | [Bb]in/ 23 | [Oo]bj/ 24 | 25 | # Visual Studo 2015 cache/options directory 26 | .vs/ 27 | 28 | # MSTest test Results 29 | [Tt]est[Rr]esult*/ 30 | [Bb]uild[Ll]og.* 31 | 32 | # NUNIT 33 | *.VisualState.xml 34 | TestResult.xml 35 | 36 | # Build Results of an ATL Project 37 | [Dd]ebugPS/ 38 | [Rr]eleasePS/ 39 | dlldata.c 40 | 41 | *_i.c 42 | *_p.c 43 | *_i.h 44 | *.ilk 45 | *.meta 46 | *.obj 47 | *.pch 48 | *.pdb 49 | *.pgc 50 | *.pgd 51 | *.rsp 52 | *.sbr 53 | *.tlb 54 | *.tli 55 | *.tlh 56 | *.tmp 57 | *.tmp_proj 58 | *.log 59 | *.vspscc 60 | *.vssscc 61 | .builds 62 | *.pidb 63 | *.svclog 64 | *.scc 65 | 66 | # Chutzpah Test files 67 | _Chutzpah* 68 | 69 | # Visual C++ cache files 70 | ipch/ 71 | *.aps 72 | *.ncb 73 | *.opensdf 74 | *.sdf 75 | *.cachefile 76 | 77 | # Visual Studio profiler 78 | *.psess 79 | *.vsp 80 | *.vspx 81 | 82 | # TFS 2012 Local Workspace 83 | $tf/ 84 | 85 | # Guidance Automation Toolkit 86 | *.gpState 87 | 88 | # ReSharper is a .NET coding add-in 89 | _ReSharper*/ 90 | *.[Rr]e[Ss]harper 91 | *.DotSettings.user 92 | 93 | # JustCode is a .NET coding addin-in 94 | .JustCode 95 | 96 | # TeamCity is a build add-in 97 | _TeamCity* 98 | 99 | # DotCover is a Code Coverage Tool 100 | *.dotCover 101 | 102 | # NCrunch 103 | _NCrunch_* 104 | .*crunch*.local.xml 105 | 106 | # MightyMoose 107 | *.mm.* 108 | AutoTest.Net/ 109 | 110 | # Web workbench (sass) 111 | .sass-cache/ 112 | 113 | # Installshield output folder 114 | [Ee]xpress/ 115 | 116 | # DocProject is a documentation generator add-in 117 | DocProject/buildhelp/ 118 | DocProject/Help/*.HxT 119 | DocProject/Help/*.HxC 120 | DocProject/Help/*.hhc 121 | DocProject/Help/*.hhk 122 | DocProject/Help/*.hhp 123 | DocProject/Help/Html2 124 | DocProject/Help/html 125 | 126 | # Click-Once directory 127 | publish/ 128 | 129 | # Publish Web Output 130 | *.[Pp]ublish.xml 131 | *.azurePubxml 132 | # TODO: Comment the next line if you want to checkin your web deploy settings 133 | # but database connection strings (with potential passwords) will be unencrypted 134 | *.pubxml 135 | *.publishproj 136 | 137 | # NuGet Packages 138 | *.nupkg 139 | # The packages folder can be ignored because of Package Restore 140 | **/packages/* 141 | # except build/, which is used as an MSBuild target. 142 | !**/packages/build/ 143 | # Uncomment if necessary however generally it will be regenerated when needed 144 | #!**/packages/repositories.config 145 | 146 | # Windows Azure Build Output 147 | csx/ 148 | *.build.csdef 149 | 150 | # Windows Store app package directory 151 | AppPackages/ 152 | 153 | # Others 154 | *.[Cc]ache 155 | ClientBin/ 156 | [Ss]tyle[Cc]op.* 157 | ~$* 158 | *~ 159 | *.dbmdl 160 | *.dbproj.schemaview 161 | *.pfx 162 | *.publishsettings 163 | node_modules/ 164 | bower_components/ 165 | 166 | # RIA/Silverlight projects 167 | Generated_Code/ 168 | 169 | # Backup & report files from converting an old project file 170 | # to a newer Visual Studio version. Backup files are not needed, 171 | # because we have git ;-) 172 | _UpgradeReport_Files/ 173 | Backup*/ 174 | UpgradeLog*.XML 175 | UpgradeLog*.htm 176 | 177 | # SQL Server files 178 | *.mdf 179 | *.ldf 180 | 181 | # Business Intelligence projects 182 | *.rdl.data 183 | *.bim.layout 184 | *.bim_*.settings 185 | 186 | # Microsoft Fakes 187 | FakesAssemblies/ 188 | 189 | # Node.js Tools for Visual Studio 190 | .ntvs_analysis.dat 191 | 192 | # Visual Studio 6 build log 193 | *.plg 194 | 195 | # Visual Studio 6 workspace options file 196 | *.opt 197 | -------------------------------------------------------------------------------- /skin/360SafeRes/ComputerExamine.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 |