Professional Documents
Culture Documents
#Region Includes
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
Global Const
$color_aqua = 65535
$color_black = 0
$color_blue = 255
$color_cream = 16776176
$color_fuchsia = 16711935
$color_gray = 8421504
$color_green = 32768
$color_lime = 65280
$color_maroon = 9116770
$color_medblue = 708
$color_medgray = 10526884
$color_moneygreen = 12639424
$color_navy = 128
$color_olive = 8421376
$color_purple = 8388736
$color_red = 16711680
$color_silver = 12632256
$color_skyblue = 10930928
$color_teal = 32896
$color_white = 16777215
$color_yellow = 16776960
$clr_none = -1
$clr_default = -16777216
$clr_aqua = 16776960
$clr_black = 0
$clr_blue = 16711680
$clr_cream = 15793151
$clr_fuchsia = 16711935
$clr_gray = 8421504
$clr_green = 32768
$clr_lime = 65280
$clr_maroon = 6429835
$clr_medblue = 12845568
$clr_medgray = 10789024
$clr_moneygreen = 12639424
$clr_navy = 8388608
$clr_olive = 32896
$clr_purple = 8388736
$clr_red = 255
$clr_silver = 12632256
$clr_skyblue = 15780518
$clr_teal = 8421376
$clr_white = 16777215
$clr_yellow = 65535
$cc_anycolor = 256
$cc_fullopen = 2
$cc_rgbinit = 1
$bs_groupbox = 7
$bs_bottom = 2048
$bs_center = 768
$bs_defpushbutton = 1
$bs_left = 256
$bs_multiline = 8192
$bs_pushbox = 10
$bs_pushlike = 4096
$bs_right = 512
$bs_rightbutton = 32
$bs_top = 1024
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$bs_vcenter = 3072
$bs_flat = 32768
$bs_icon = 64
$bs_bitmap = 128
$bs_notify = 16384
$bs_splitbutton = 12
$bs_defsplitbutton = 13
$bs_commandlink = 14
$bs_defcommandlink = 15
$bcsif_glyph = 1
$bcsif_image = 2
$bcsif_style = 4
$bcsif_size = 8
$bcss_nosplit = 1
$bcss_stretch = 2
$bcss_alignleft = 4
$bcss_image = 8
$button_imagelist_align_left = 0
$button_imagelist_align_right = 1
$button_imagelist_align_top = 2
$button_imagelist_align_bottom = 3
$button_imagelist_align_center = 4
$bs_3state = 5
$bs_auto3state = 6
$bs_autocheckbox = 3
$bs_checkbox = 2
$bs_radiobutton = 4
$bs_autoradiobutton = 9
$bs_ownerdraw = 11
$gui_ss_default_button = 0
$gui_ss_default_checkbox = 0
$gui_ss_default_group = 0
$gui_ss_default_radio = 0
$bcm_first = 5632
$bcm_getidealsize = ($bcm_first + 1)
$bcm_getimagelist = ($bcm_first + 3)
$bcm_getnote = ($bcm_first + 10)
$bcm_getnotelength = ($bcm_first + 11)
$bcm_getsplitinfo = ($bcm_first + 8)
$bcm_gettextmargin = ($bcm_first + 5)
$bcm_setdropdownstate = ($bcm_first + 6)
$bcm_setimagelist = ($bcm_first + 2)
$bcm_setnote = ($bcm_first + 9)
$bcm_setshield = ($bcm_first + 12)
$bcm_setsplitinfo = ($bcm_first + 7)
$bcm_settextmargin = ($bcm_first + 4)
$bm_click = 245
$bm_getcheck = 240
$bm_getimage = 246
$bm_getstate = 242
$bm_setcheck = 241
$bm_setdontclick = 248
$bm_setimage = 247
$bm_setstate = 243
$bm_setstyle = 244
$bcn_first = -1250
$bcn_dropdown = ($bcn_first + 2)
$bcn_hotitemchange = ($bcn_first + 1)
$bn_clicked = 0
$bn_paint = 1
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$bn_hilite = 2
$bn_unhilite = 3
$bn_disable = 4
$bn_doubleclicked = 5
$bn_setfocus = 6
$bn_killfocus = 7
$bn_pushed = $bn_hilite
$bn_unpushed = $bn_unhilite
$bn_dblclk = $bn_doubleclicked
$bst_checked = 1
$bst_indeterminate = 2
$bst_unchecked = 0
$bst_focus = 8
$bst_pushed = 4
$bst_dontclick = 128
$cb_err = -1
$cb_errattribute = -3
$cb_errrequired = -4
$cb_errspace = -2
$cb_okay = 0
$state_system_invisible = 32768
$state_system_pressed = 8
$cbs_autohscroll = 64
$cbs_disablenoscroll = 2048
$cbs_dropdown = 2
$cbs_dropdownlist = 3
$cbs_hasstrings = 512
$cbs_lowercase = 16384
$cbs_nointegralheight = 1024
$cbs_oemconvert = 128
$cbs_ownerdrawfixed = 16
$cbs_ownerdrawvariable = 32
$cbs_simple = 1
$cbs_sort = 256
$cbs_uppercase = 8192
$cbm_first = 5888
$cb_addstring = 323
$cb_deletestring = 324
$cb_dir = 325
$cb_findstring = 332
$cb_findstringexact = 344
$cb_getcomboboxinfo = 356
$cb_getcount = 326
$cb_getcuebanner = ($cbm_first + 4)
$cb_getcursel = 327
$cb_getdroppedcontrolrect = 338
$cb_getdroppedstate = 343
$cb_getdroppedwidth = 351
$cb_geteditsel = 320
$cb_getextendedui = 342
$cb_gethorizontalextent = 349
$cb_getitemdata = 336
$cb_getitemheight = 340
$cb_getlbtext = 328
$cb_getlbtextlen = 329
$cb_getlocale = 346
$cb_getminvisible = 5890
$cb_gettopindex = 347
$cb_initstorage = 353
$cb_limittext = 321
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$cb_resetcontent = 331
$cb_insertstring = 330
$cb_selectstring = 333
$cb_setcuebanner = ($cbm_first + 3)
$cb_setcursel = 334
$cb_setdroppedwidth = 352
$cb_seteditsel = 322
$cb_setextendedui = 341
$cb_sethorizontalextent = 350
$cb_setitemdata = 337
$cb_setitemheight = 339
$cb_setlocale = 345
$cb_setminvisible = 5889
$cb_settopindex = 348
$cb_showdropdown = 335
$cbn_closeup = 8
$cbn_dblclk = 2
$cbn_dropdown = 7
$cbn_editchange = 5
$cbn_editupdate = 6
$cbn_errspace = (-1)
$cbn_killfocus = 4
$cbn_selchange = 1
$cbn_selendcancel = 10
$cbn_selendok = 9
$cbn_setfocus = 3
$cbes_ex_casesensitive = 16
$cbes_ex_noeditimage = 1
$cbes_ex_noeditimageindent = 2
$cbes_ex_nosizelimit = 8
$__comboboxconstant_wm_user = 1024
$cbem_deleteitem = $cb_deletestring
$cbem_getcombocontrol = ($__comboboxconstant_wm_user + 6)
$cbem_geteditcontrol = ($__comboboxconstant_wm_user + 7)
$cbem_getexstyle = ($__comboboxconstant_wm_user + 9)
$cbem_getextendedstyle = ($__comboboxconstant_wm_user + 9)
$cbem_getimagelist = ($__comboboxconstant_wm_user + 3)
$cbem_getitema = ($__comboboxconstant_wm_user + 4)
$cbem_getitemw = ($__comboboxconstant_wm_user + 13)
$cbem_getunicodeformat = 8192 + 6
$cbem_haseditchanged = ($__comboboxconstant_wm_user + 10)
$cbem_insertitema = ($__comboboxconstant_wm_user + 1)
$cbem_insertitemw = ($__comboboxconstant_wm_user + 11)
$cbem_setexstyle = ($__comboboxconstant_wm_user + 8)
$cbem_setextendedstyle = ($__comboboxconstant_wm_user + 14)
$cbem_setimagelist = ($__comboboxconstant_wm_user + 2)
$cbem_setitema = ($__comboboxconstant_wm_user + 5)
$cbem_setitemw = ($__comboboxconstant_wm_user + 12)
$cbem_setunicodeformat = 8192 + 5
$cbem_setwindowtheme = 8192 + 11
$cben_first = (-800)
$cben_last = (-830)
$cben_beginedit = ($cben_first - 4)
$cben_deleteitem = ($cben_first - 2)
$cben_dragbegina = ($cben_first - 8)
$cben_dragbeginw = ($cben_first - 9)
$cben_endedita = ($cben_first - 5)
$cben_endeditw = ($cben_first - 6)
$cben_getdispinfo = ($cben_first + 0)
$cben_getdispinfoa = ($cben_first + 0)
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$cben_getdispinfow = ($cben_first - 7)
$cben_insertitem = ($cben_first - 1)
$cbeif_di_setitem = 268435456
$cbeif_image = 2
$cbeif_indent = 16
$cbeif_lparam = 32
$cbeif_overlay = 8
$cbeif_selectedimage = 4
$cbeif_text = 1
$gui_ss_default_combo = 2097218
$es_left = 0
$es_center = 1
$es_right = 2
$es_multiline = 4
$es_uppercase = 8
$es_lowercase = 16
$es_password = 32
$es_autovscroll = 64
$es_autohscroll = 128
$es_nohidesel = 256
$es_oemconvert = 1024
$es_readonly = 2048
$es_wantreturn = 4096
$es_number = 8192
$ec_err = -1
$ecm_first = 5376
$em_canundo = 198
$em_charfrompos = 215
$em_emptyundobuffer = 205
$em_fmtlines = 200
$em_getcuebanner = ($ecm_first + 2)
$em_getfirstvisibleline = 206
$em_gethandle = 189
$em_getimestatus = 217
$em_getlimittext = 213
$em_getline = 196
$em_getlinecount = 186
$em_getmargins = 212
$em_getmodify = 184
$em_getpasswordchar = 210
$em_getrect = 178
$em_getsel = 176
$em_getthumb = 190
$em_getwordbreakproc = 209
$em_hideballoontip = ($ecm_first + 4)
$em_limittext = 197
$em_linefromchar = 201
$em_lineindex = 187
$em_linelength = 193
$em_linescroll = 182
$em_posfromchar = 214
$em_replacesel = 194
$em_scroll = 181
$em_scrollcaret = 183
$em_setcuebanner = ($ecm_first + 1)
$em_sethandle = 188
$em_setimestatus = 216
$em_setlimittext = $em_limittext
$em_setmargins = 211
$em_setmodify = 185
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$em_setpasswordchar = 204
$em_setreadonly = 207
$em_setrect = 179
$em_setrectnp = 180
$em_setsel = 177
$em_settabstops = 203
$em_setwordbreakproc = 208
$em_showballoontip = ($ecm_first + 3)
$em_undo = 199
$ec_leftmargin = 1
$ec_rightmargin = 2
$ec_usefontinfo = 65535
$emsis_compositionstring = 1
$eimes_getcompstratonce = 1
$eimes_cancelcompstrinfocus = 2
$eimes_completecompstrkillfocus = 4
$en_align_ltr_ec = 1792
$en_align_rtl_ec = 1793
$en_change = 768
$en_errspace = 1280
$en_hscroll = 1537
$en_killfocus = 512
$en_maxtext = 1281
$en_setfocus = 256
$en_update = 1024
$en_vscroll = 1538
$gui_ss_default_edit = 3150016
$gui_ss_default_input = 128
$gui_event_single = 0
$gui_event_array = 1
$gui_event_none = 0
$gui_event_close = -3
$gui_event_minimize = -4
$gui_event_restore = -5
$gui_event_maximize = -6
$gui_event_primarydown = -7
$gui_event_primaryup = -8
$gui_event_secondarydown = -9
$gui_event_secondaryup = -10
$gui_event_mousemove = -11
$gui_event_resized = -12
$gui_event_dropped = -13
$gui_rundefmsg = "GUI_RUNDEFMSG"
$gui_avistop = 0
$gui_avistart = 1
$gui_aviclose = 2
$gui_checked = 1
$gui_indeterminate = 2
$gui_unchecked = 4
$gui_dropaccepted = 8
$gui_nodropaccepted = 4096
$gui_acceptfiles = $gui_dropaccepted
$gui_show = 16
$gui_hide = 32
$gui_enable = 64
$gui_disable = 128
$gui_focus = 256
$gui_nofocus = 8192
$gui_defbutton = 512
$gui_expand = 1024
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$gui_ontop = 2048
$gui_fontnormal = 0
$gui_fontitalic = 2
$gui_fontunder = 4
$gui_fontstrike = 8
$gui_dockauto = 1
$gui_dockleft = 2
$gui_dockright = 4
$gui_dockhcenter = 8
$gui_docktop = 32
$gui_dockbottom = 64
$gui_dockvcenter = 128
$gui_dockwidth = 256
$gui_dockheight = 512
$gui_docksize = 768
$gui_dockmenubar = 544
$gui_dockstatebar = 576
$gui_dockall = 802
$gui_dockborders = 102
$gui_gr_close = 1
$gui_gr_line = 2
$gui_gr_bezier = 4
$gui_gr_move = 6
$gui_gr_color = 8
$gui_gr_rect = 10
$gui_gr_ellipse = 12
$gui_gr_pie = 14
$gui_gr_dot = 16
$gui_gr_pixel = 18
$gui_gr_hint = 20
$gui_gr_refresh = 22
$gui_gr_pensize = 24
$gui_gr_nobkcolor = -2
$gui_bkcolor_default = -1
$gui_bkcolor_transparent = -2
$gui_bkcolor_lv_alternate = -33554432
$gui_read_default = 0
$gui_read_extended = 1
$gui_cursor_nooverride = 0
$gui_cursor_override = 1
$gui_ws_ex_parentdrag = 1048576
$lvgs_normal = 0
$lvgs_collapsed = 1
$lvgs_hidden = 2
$lvgs_noheader = 4
$lvgs_collapsible = 8
$lvgs_focused = 16
$lvgs_selected = 32
$lvgs_subseted = 64
$lvgs_subsetlinkfocused = 128
$lvggr_group = 0
$lvggr_header = 1
$lvggr_label = 2
$lvggr_subsetlink = 3
$lv_err = -1
$lvbkif_source_none = 0
$lvbkif_source_hbitmap = 1
$lvbkif_source_url = 2
$lvbkif_source_mask = 3
$lvbkif_style_normal = 0
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
fmt_fill)
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$lvbkif_style_tile = 16
$lvbkif_style_mask = 16
$lvbkif_flag_tileoffset = 256
$lvbkif_type_watermark = 268435456
$lv_view_details = 1
$lv_view_icon = 0
$lv_view_list = 3
$lv_view_smallicon = 2
$lv_view_tile = 4
$lva_alignleft = 1
$lva_aligntop = 2
$lva_default = 0
$lva_snaptogrid = 5
$lvcdi_item = 0
$lvcdi_group = 1
$lvcf_alldata = 63
$lvcf_fmt = 1
$lvcf_image = 16
$lvcfmt_justifymask = 3
$lvcf_text = 4
$lvcf_width = 2
$lvcfmt_bitmap_on_right = 4096
$lvcfmt_center = 2
$lvcfmt_col_has_images = 32768
$lvcfmt_image = 2048
$lvcfmt_left = 0
$lvcfmt_right = 1
$lvcfmt_line_break = 1048576
$lvcfmt_fill = 2097152
$lvcfmt_wrap = 4194304
$lvcfmt_no_title = 8388608
$lvcfmt_tile_placementmask = BitOR($lvcfmt_line_break, $lvc
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$lvfi_nearestxy = 64
$lvfi_param = 1
$lvfi_partial = 8
$lvfi_string = 2
$lvfi_substring = 4
$lvfi_wrap = 32
$lvga_footer_left = 8
$lvga_footer_center = 16
$lvga_footer_right = 32
$lvga_header_left = 1
$lvga_header_center = 2
$lvga_header_right = 4
$lvgf_align = 8
$lvgf_descriptiontop = 1024
$lvgf_descriptionbottom = 2048
$lvgf_extendedimage = 8192
$lvgf_footer = 2
$lvgf_groupid = 16
$lvgf_header = 1
$lvgf_items = 16384
$lvgf_none = 0
$lvgf_state = 4
$lvgf_subset = 32768
$lvgf_subsetitems = 65536
$lvgf_subtitle = 256
$lvgf_task = 512
$lvgf_titleimage = 4096
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
inglesel)
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$lvs_sortascending = 16
$lvs_sortdescending = 32
$lvs_typemask = 3
$lvs_typestylemask = 64512
$lvs_ex_autoautoarrange = 16777216
$lvs_ex_autocheckselect = 134217728
$lvs_ex_autosizecolumns = 268435456
$lvs_ex_borderselect = 32768
$lvs_ex_checkboxes = 4
$lvs_ex_columnoverflow = -2147483648
$lvs_ex_columnsnappoints = 1073741824
$lvs_ex_doublebuffer = 65536
$lvs_ex_flatsb = 256
$lvs_ex_fullrowselect = 32
$lvs_ex_gridlines = 1
$lvs_ex_headerdragdrop = 16
$lvs_ex_headerinallviews = 33554432
$lvs_ex_hidelabels = 131072
$lvs_ex_infotip = 1024
$lvs_ex_justifycolumns = 2097152
$lvs_ex_labeltip = 16384
$lvs_ex_multiworkareas = 8192
$lvs_ex_oneclickactivate = 64
$lvs_ex_regional = 512
$lvs_ex_simpleselect = 1048576
$lvs_ex_snaptogrid = 524288
$lvs_ex_subitemimages = 2
$lvs_ex_trackselect = 8
$lvs_ex_transparentbkgnd = 4194304
$lvs_ex_transparentshadowtext = 8388608
$lvs_ex_twoclickactivate = 128
$lvs_ex_underlinecold = 4096
$lvs_ex_underlinehot = 2048
$gui_ss_default_listview = BitOR($lvs_showselalways, $lvs_s
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$lvm_first = 4096
$lvm_approximateviewrect = ($lvm_first + 64)
$lvm_arrange = ($lvm_first + 22)
$lvm_canceleditlabel = ($lvm_first + 179)
$lvm_createdragimage = ($lvm_first + 33)
$lvm_deleteallitems = ($lvm_first + 9)
$lvm_deletecolumn = ($lvm_first + 28)
$lvm_deleteitem = ($lvm_first + 8)
$lvm_editlabela = ($lvm_first + 23)
$lvm_editlabelw = ($lvm_first + 118)
$lvm_editlabel = $lvm_editlabela
$lvm_enablegroupview = ($lvm_first + 157)
$lvm_ensurevisible = ($lvm_first + 19)
$lvm_finditem = ($lvm_first + 13)
$lvm_getbkcolor = ($lvm_first + 0)
$lvm_getbkimagea = ($lvm_first + 69)
$lvm_getbkimagew = ($lvm_first + 139)
$lvm_getcallbackmask = ($lvm_first + 10)
$lvm_getcolumna = ($lvm_first + 25)
$lvm_getcolumnw = ($lvm_first + 95)
$lvm_getcolumnorderarray = ($lvm_first + 59)
$lvm_getcolumnwidth = ($lvm_first + 29)
$lvm_getcountperpage = ($lvm_first + 40)
$lvm_geteditcontrol = ($lvm_first + 24)
$lvm_getemptytext = ($lvm_first + 204)
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$ss_simple = 11
$ss_leftnowordwrap = 12
$ss_bitmap = 14
$ss_enhmetafile = 15
$ss_etchedhorz = 16
$ss_etchedvert = 17
$ss_etchedframe = 18
$ss_realsizecontrol = 64
$ss_noprefix = 128
$ss_notify = 256
$ss_centerimage = 512
$ss_rightjust = 1024
$ss_sunken = 4096
$gui_ss_default_label = 0
$gui_ss_default_graphic = 0
$gui_ss_default_icon = $ss_notify
$gui_ss_default_pic = $ss_notify
$stm_seticon = 368
$stm_geticon = 369
$stm_setimage = 370
$stm_getimage = 371
$sbars_sizegrip = 256
$sbt_tooltips = 2048
$sbars_tooltips = 2048
$sbt_sunken = 0
$sbt_noborders = 256
$sbt_popout = 512
$sbt_rtlreading = 1024
$sbt_notabparsing = 2048
$sbt_ownerdraw = 4096
$__statusbarconstant_wm_user = 1024
$sb_getborders = ($__statusbarconstant_wm_user + 7)
$sb_geticon = ($__statusbarconstant_wm_user + 20)
$sb_getparts = ($__statusbarconstant_wm_user + 6)
$sb_getrect = ($__statusbarconstant_wm_user + 10)
$sb_gettexta = ($__statusbarconstant_wm_user + 2)
$sb_gettextw = ($__statusbarconstant_wm_user + 13)
$sb_gettext = $sb_gettexta
$sb_gettextlengtha = ($__statusbarconstant_wm_user + 3)
$sb_gettextlengthw = ($__statusbarconstant_wm_user + 12)
$sb_gettextlength = $sb_gettextlengtha
$sb_gettiptexta = ($__statusbarconstant_wm_user + 18)
$sb_gettiptextw = ($__statusbarconstant_wm_user + 19)
$sb_getunicodeformat = 8192 + 6
$sb_issimple = ($__statusbarconstant_wm_user + 14)
$sb_setbkcolor = 8192 + 1
$sb_seticon = ($__statusbarconstant_wm_user + 15)
$sb_setminheight = ($__statusbarconstant_wm_user + 8)
$sb_setparts = ($__statusbarconstant_wm_user + 4)
$sb_settexta = ($__statusbarconstant_wm_user + 1)
$sb_settextw = ($__statusbarconstant_wm_user + 11)
$sb_settext = $sb_settexta
$sb_settiptexta = ($__statusbarconstant_wm_user + 16)
$sb_settiptextw = ($__statusbarconstant_wm_user + 17)
$sb_setunicodeformat = 8192 + 5
$sb_simple = ($__statusbarconstant_wm_user + 9)
$sb_simpleid = 255
$sbn_first = -880
$sbn_simplemodechange = $sbn_first + 0
$tcs_ex_flatseparators = 1
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$tcs_ex_registerdrop = 2
$tcht_nowhere = 1
$tcht_onitemicon = 2
$tcht_onitemlabel = 4
$tcht_onitem = 6
$tcif_text = 1
$tcif_image = 2
$tcif_rtlreading = 4
$tcif_param = 8
$tcif_state = 16
$tcif_alldata = 27
$tcis_buttonpressed = 1
$tcis_highlighted = 2
$tc_err = -1
$tcs_bottom = 2
$tcs_buttons = 256
$tcs_fixedwidth = 1024
$tcs_flatbuttons = 8
$tcs_focusnever = 32768
$tcs_focusonbuttondown = 4096
$tcs_forceiconleft = 16
$tcs_forcelabelleft = 32
$tcs_hottrack = 64
$tcs_multiline = 512
$tcs_multiselect = 4
$tcs_ownerdrawfixed = 8192
$tcs_raggedright = 2048
$tcs_right = 2
$tcs_rightjustify = 0
$tcs_scrollopposite = 1
$tcs_singleline = 0
$tcs_tabs = 0
$tcs_tooltips = 16384
$tcs_vertical = 128
$gui_ss_default_tab = 0
$tcm_first = 4864
$tccm_first = 8192
$tcm_adjustrect = ($tcm_first + 40)
$tcm_deleteallitems = ($tcm_first + 9)
$tcm_deleteitem = ($tcm_first + 8)
$tcm_deselectall = ($tcm_first + 50)
$tcm_getcurfocus = ($tcm_first + 47)
$tcm_getcursel = ($tcm_first + 11)
$tcm_getextendedstyle = ($tcm_first + 53)
$tcm_getimagelist = ($tcm_first + 2)
$tcm_getitema = ($tcm_first + 5)
$tcm_getitemw = ($tcm_first + 60)
$tcm_getitemcount = ($tcm_first + 4)
$tcm_getitemrect = ($tcm_first + 10)
$tcm_getrowcount = ($tcm_first + 44)
$tcm_gettooltips = ($tcm_first + 45)
$tccm_getunicodeformat = ($tccm_first + 6)
$tcm_getunicodeformat = $tccm_getunicodeformat
$tcm_highlightitem = ($tcm_first + 51)
$tcm_hittest = ($tcm_first + 13)
$tcm_insertitema = ($tcm_first + 7)
$tcm_insertitemw = ($tcm_first + 62)
$tcm_removeimage = ($tcm_first + 42)
$tcm_setitema = ($tcm_first + 6)
$tcm_setitemw = ($tcm_first + 61)
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$wm_activate = 6
$wm_setfocus = 7
$wm_killfocus = 8
$wm_setvisible = 9
$wm_enable = 10
$wm_setredraw = 11
$wm_settext = 12
$wm_gettext = 13
$wm_gettextlength = 14
$wm_paint = 15
$wm_close = 16
$wm_queryendsession = 17
$wm_quit = 18
$wm_erasebkgnd = 20
$wm_queryopen = 19
$wm_syscolorchange = 21
$wm_endsession = 22
$wm_systemerror = 23
$wm_showwindow = 24
$wm_ctlcolor = 25
$wm_settingchange = 26
$wm_wininichange = 26
$wm_devmodechange = 27
$wm_activateapp = 28
$wm_fontchange = 29
$wm_timechange = 30
$wm_cancelmode = 31
$wm_setcursor = 32
$wm_mouseactivate = 33
$wm_childactivate = 34
$wm_queuesync = 35
$wm_getminmaxinfo = 36
$wm_logoff = 37
$wm_painticon = 38
$wm_iconerasebkgnd = 39
$wm_nextdlgctl = 40
$wm_alttabactive = 41
$wm_spoolerstatus = 42
$wm_drawitem = 43
$wm_measureitem = 44
$wm_deleteitem = 45
$wm_vkeytoitem = 46
$wm_chartoitem = 47
$wm_setfont = 48
$wm_getfont = 49
$wm_sethotkey = 50
$wm_gethotkey = 51
$wm_filesyschange = 52
$wm_isactiveicon = 53
$wm_queryparkicon = 54
$wm_querydragicon = 55
$wm_winhelp = 56
$wm_compareitem = 57
$wm_fullscreen = 58
$wm_clientshutdown = 59
$wm_ddemlevent = 60
$wm_getobject = 61
$wm_calcscroll = 63
$wm_testing = 64
$wm_compacting = 65
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$wm_otherwindowcreated = 66
$wm_otherwindowdestroyed = 67
$wm_commnotify = 68
$wm_mediastatuschange = 69
$wm_windowposchanging = 70
$wm_windowposchanged = 71
$wm_power = 72
$wm_copyglobaldata = 73
$wm_copydata = 74
$wm_canceljournal = 75
$wm_logonnotify = 76
$wm_keyf1 = 77
$wm_notify = 78
$wm_access_window = 79
$wm_inputlangchangerequest = 80
$wm_inputlangchange = 81
$wm_tcard = 82
$wm_help = 83
$wm_userchanged = 84
$wm_notifyformat = 85
$wm_qm_activate = 96
$wm_hook_do_callback = 97
$wm_syscopydata = 98
$wm_finaldestroy = 112
$wm_measureitem_clientdata = 113
$wm_contextmenu = 123
$wm_stylechanging = 124
$wm_stylechanged = 125
$wm_displaychange = 126
$wm_geticon = 127
$wm_seticon = 128
$wm_nccreate = 129
$wm_ncdestroy = 130
$wm_nccalcsize = 131
$wm_nchittest = 132
$wm_ncpaint = 133
$wm_ncactivate = 134
$wm_getdlgcode = 135
$wm_syncpaint = 136
$wm_synctask = 137
$wm_kludgeminrect = 139
$wm_lpkdrawswitchwnd = 140
$wm_uahdestroywindow = 144
$wm_uahdrawmenu = 145
$wm_uahdrawmenuitem = 146
$wm_uahinitmenu = 147
$wm_uahmeasuremenuitem = 148
$wm_uahncpaintmenupopup = 149
$wm_ncmousemove = 160
$wm_nclbuttondown = 161
$wm_nclbuttonup = 162
$wm_nclbuttondblclk = 163
$wm_ncrbuttondown = 164
$wm_ncrbuttonup = 165
$wm_ncrbuttondblclk = 166
$wm_ncmbuttondown = 167
$wm_ncmbuttonup = 168
$wm_ncmbuttondblclk = 169
$wm_ncxbuttondown = 171
$wm_ncxbuttonup = 172
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$wm_ncxbuttondblclk = 173
$wm_ncuahdrawcaption = 174
$wm_ncuahdrawframe = 175
$wm_input_device_change = 254
$wm_input = 255
$wm_keydown = 256
$wm_keyfirst = 256
$wm_keyup = 257
$wm_char = 258
$wm_deadchar = 259
$wm_syskeydown = 260
$wm_syskeyup = 261
$wm_syschar = 262
$wm_sysdeadchar = 263
$wm_yomichar = 264
$wm_keylast = 265
$wm_unichar = 265
$wm_convertrequest = 266
$wm_convertresult = 267
$wm_im_info = 268
$wm_ime_startcomposition = 269
$wm_ime_endcomposition = 270
$wm_ime_composition = 271
$wm_ime_keylast = 271
$wm_initdialog = 272
$wm_command = 273
$wm_syscommand = 274
$wm_timer = 275
$wm_hscroll = 276
$wm_vscroll = 277
$wm_initmenu = 278
$wm_initmenupopup = 279
$wm_systimer = 280
$wm_gesture = 281
$wm_gesturenotify = 282
$wm_gestureinput = 283
$wm_gesturenotified = 284
$wm_menuselect = 287
$wm_menuchar = 288
$wm_enteridle = 289
$wm_menurbuttonup = 290
$wm_menudrag = 291
$wm_menugetobject = 292
$wm_uninitmenupopup = 293
$wm_menucommand = 294
$wm_changeuistate = 295
$wm_updateuistate = 296
$wm_queryuistate = 297
$wm_lbtrackpoint = 305
$wm_ctlcolormsgbox = 306
$wm_ctlcoloredit = 307
$wm_ctlcolorlistbox = 308
$wm_ctlcolorbtn = 309
$wm_ctlcolordlg = 310
$wm_ctlcolorscrollbar = 311
$wm_ctlcolorstatic = 312
$mn_gethmenu = 481
$wm_parentnotify = 528
$wm_entermenuloop = 529
$wm_exitmenuloop = 530
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$wm_nextmenu = 531
$wm_sizing = 532
$wm_capturechanged = 533
$wm_moving = 534
$wm_powerbroadcast = 536
$wm_devicechange = 537
$wm_mdicreate = 544
$wm_mdidestroy = 545
$wm_mdiactivate = 546
$wm_mdirestore = 547
$wm_mdinext = 548
$wm_mdimaximize = 549
$wm_mditile = 550
$wm_mdicascade = 551
$wm_mdiiconarrange = 552
$wm_mdigetactive = 553
$wm_dropobject = 554
$wm_querydropobject = 555
$wm_begindrag = 556
$wm_dragloop = 557
$wm_dragselect = 558
$wm_dragmove = 559
$wm_mdisetmenu = 560
$wm_entersizemove = 561
$wm_exitsizemove = 562
$wm_dropfiles = 563
$wm_mdirefreshmenu = 564
$wm_touch = 576
$wm_ime_setcontext = 641
$wm_ime_notify = 642
$wm_ime_control = 643
$wm_ime_compositionfull = 644
$wm_ime_select = 645
$wm_ime_char = 646
$wm_ime_system = 647
$wm_ime_request = 648
$wm_ime_keydown = 656
$wm_ime_keyup = 657
$wm_ncmousehover = 672
$wm_mousehover = 673
$wm_ncmouseleave = 674
$wm_mouseleave = 675
$wm_wtssession_change = 689
$wm_tablet_first = 704
$wm_tablet_last = 735
$wm_cut = 768
$wm_copy = 769
$wm_paste = 770
$wm_clear = 771
$wm_undo = 772
$wm_paletteischanging = 784
$wm_hotkey = 786
$wm_palettechanged = 785
$wm_sysmenu = 787
$wm_hookmsg = 788
$wm_exitprocess = 789
$wm_wakethread = 790
$wm_print = 791
$wm_printclient = 792
$wm_appcommand = 793
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$wm_querynewpalette = 783
$wm_themechanged = 794
$wm_uahinit = 795
$wm_desktopnotify = 796
$wm_clipboardupdate = 797
$wm_dwmcompositionchanged = 798
$wm_dwmncrenderingchanged = 799
$wm_dwmcolorizationcolorchanged = 800
$wm_dwmwindowmaximizedchange = 801
$wm_dwmexileframe = 802
$wm_dwmsendiconicthumbnail = 803
$wm_magnification_started = 804
$wm_magnification_ended = 805
$wm_dwmsendiconiclivepreviewbitmap = 806
$wm_dwmthumbnailsizechanged = 807
$wm_magnification_output = 808
$wm_measurecontrol = 816
$wm_getactiontext = 817
$wm_forwardkeydown = 819
$wm_forwardkeyup = 820
$wm_gettitlebarinfoex = 831
$wm_notifywow = 832
$wm_handheldfirst = 856
$wm_handheldlast = 863
$wm_afxfirst = 864
$wm_afxlast = 895
$wm_penwinfirst = 896
$wm_penwinlast = 911
$wm_dde_initiate = 992
$wm_dde_terminate = 993
$wm_dde_advise = 994
$wm_dde_unadvise = 995
$wm_dde_ack = 996
$wm_dde_data = 997
$wm_dde_request = 998
$wm_dde_poke = 999
$wm_dde_execute = 1000
$wm_dbnotification = 1021
$wm_netconnect = 1022
$wm_hibernate = 1023
$wm_user = 1024
$wm_app = 32768
$nm_first = 0
$nm_outofmemory = $nm_first - 1
$nm_click = $nm_first - 2
$nm_dblclk = $nm_first - 3
$nm_return = $nm_first - 4
$nm_rclick = $nm_first - 5
$nm_rdblclk = $nm_first - 6
$nm_setfocus = $nm_first - 7
$nm_killfocus = $nm_first - 8
$nm_customdraw = $nm_first - 12
$nm_hover = $nm_first - 13
$nm_nchittest = $nm_first - 14
$nm_keydown = $nm_first - 15
$nm_releasedcapture = $nm_first - 16
$nm_setcursor = $nm_first - 17
$nm_char = $nm_first - 18
$nm_tooltipscreated = $nm_first - 19
$nm_ldown = $nm_first - 20
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$nm_rdown = $nm_first - 21
$nm_themechanged = $nm_first - 22
$wm_mousefirst = 512
$wm_mousemove = 512
$wm_lbuttondown = 513
$wm_lbuttonup = 514
$wm_lbuttondblclk = 515
$wm_rbuttondown = 516
$wm_rbuttonup = 517
$wm_rbuttondblclk = 518
$wm_mbuttondown = 519
$wm_mbuttonup = 520
$wm_mbuttondblclk = 521
$wm_mousewheel = 522
$wm_xbuttondown = 523
$wm_xbuttonup = 524
$wm_xbuttondblclk = 525
$wm_mousehwheel = 526
$ps_solid = 0
$ps_dash = 1
$ps_dot = 2
$ps_dashdot = 3
$ps_dashdotdot = 4
$ps_null = 5
$ps_insideframe = 6
$ps_userstyle = 7
$ps_alternate = 8
$ps_endcap_round = 0
$ps_endcap_square = 256
$ps_endcap_flat = 512
$ps_join_bevel = 4096
$ps_join_miter = 8192
$ps_join_round = 0
$ps_geometric = 65536
$ps_cosmetic = 0
$lwa_alpha = 2
$lwa_colorkey = 1
$rgn_and = 1
$rgn_or = 2
$rgn_xor = 3
$rgn_diff = 4
$rgn_copy = 5
$errorregion = 0
$nullregion = 1
$simpleregion = 2
$complexregion = 3
$transparent = 1
$opaque = 2
$ccm_first = 8192
$ccm_getunicodeformat = ($ccm_first + 6)
$ccm_setunicodeformat = ($ccm_first + 5)
$ccm_setbkcolor = $ccm_first + 1
$ccm_setcolorscheme = $ccm_first + 2
$ccm_getcolorscheme = $ccm_first + 3
$ccm_getdroptarget = $ccm_first + 4
$ccm_setwindowtheme = $ccm_first + 11
$ga_parent = 1
$ga_root = 2
$ga_rootowner = 3
$sm_cxscreen = 0
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$sm_cyscreen = 1
$sm_cxvscroll = 2
$sm_cyhscroll = 3
$sm_cycaption = 4
$sm_cxborder = 5
$sm_cyborder = 6
$sm_cxdlgframe = 7
$sm_cydlgframe = 8
$sm_cyvthumb = 9
$sm_cxhthumb = 10
$sm_cxicon = 11
$sm_cyicon = 12
$sm_cxcursor = 13
$sm_cycursor = 14
$sm_cymenu = 15
$sm_cxfullscreen = 16
$sm_cyfullscreen = 17
$sm_cykanjiwindow = 18
$sm_mousepresent = 19
$sm_cyvscroll = 20
$sm_cxhscroll = 21
$sm_debug = 22
$sm_swapbutton = 23
$sm_reserved1 = 24
$sm_reserved2 = 25
$sm_reserved3 = 26
$sm_reserved4 = 27
$sm_cxmin = 28
$sm_cymin = 29
$sm_cxsize = 30
$sm_cysize = 31
$sm_cxframe = 32
$sm_cyframe = 33
$sm_cxmintrack = 34
$sm_cymintrack = 35
$sm_cxdoubleclk = 36
$sm_cydoubleclk = 37
$sm_cxiconspacing = 38
$sm_cyiconspacing = 39
$sm_menudropalignment = 40
$sm_penwindows = 41
$sm_dbcsenabled = 42
$sm_cmousebuttons = 43
$sm_secure = 44
$sm_cxedge = 45
$sm_cyedge = 46
$sm_cxminspacing = 47
$sm_cyminspacing = 48
$sm_cxsmicon = 49
$sm_cysmicon = 50
$sm_cysmcaption = 51
$sm_cxsmsize = 52
$sm_cysmsize = 53
$sm_cxmenusize = 54
$sm_cymenusize = 55
$sm_arrange = 56
$sm_cxminimized = 57
$sm_cyminimized = 58
$sm_cxmaxtrack = 59
$sm_cymaxtrack = 60
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$sm_cxmaximized = 61
$sm_cymaximized = 62
$sm_network = 63
$sm_cleanboot = 67
$sm_cxdrag = 68
$sm_cydrag = 69
$sm_showsounds = 70
$sm_cxmenucheck = 71
$sm_cymenucheck = 72
$sm_slowmachine = 73
$sm_mideastenabled = 74
$sm_mousewheelpresent = 75
$sm_xvirtualscreen = 76
$sm_yvirtualscreen = 77
$sm_cxvirtualscreen = 78
$sm_cyvirtualscreen = 79
$sm_cmonitors = 80
$sm_samedisplayformat = 81
$sm_immenabled = 82
$sm_cxfocusborder = 83
$sm_cyfocusborder = 84
$sm_tabletpc = 86
$sm_mediacenter = 87
$sm_starter = 88
$sm_serverr2 = 89
$sm_cmetrics = 90
$sm_remotesession = 4096
$sm_shuttingdown = 8192
$sm_remotecontrol = 8193
$sm_caretblinkingenabled = 8194
$blackness = 66
$captureblt = 1073741824
$dstinvert = 5570569
$mergecopy = 12583114
$mergepaint = 12255782
$nomirrorbitmap = -2147483648
$notsrccopy = 3342344
$notsrcerase = 1114278
$patcopy = 15728673
$patinvert = 5898313
$patpaint = 16452105
$srcand = 8913094
$srccopy = 13369376
$srcerase = 4457256
$srcinvert = 6684742
$srcpaint = 15597702
$whiteness = 16711778
$dt_bottom = 8
$dt_calcrect = 1024
$dt_center = 1
$dt_editcontrol = 8192
$dt_end_ellipsis = 32768
$dt_expandtabs = 64
$dt_externalleading = 512
$dt_hideprefix = 1048576
$dt_internal = 4096
$dt_left = 0
$dt_modifystring = 65536
$dt_noclip = 256
$dt_nofullwidthcharbreak = 524288
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$dt_noprefix = 2048
$dt_path_ellipsis = 16384
$dt_prefixonly = 2097152
$dt_right = 2
$dt_rtlreading = 131072
$dt_singleline = 32
$dt_tabstop = 128
$dt_top = 0
$dt_vcenter = 4
$dt_wordbreak = 16
$dt_word_ellipsis = 262144
$rdw_erase = 4
$rdw_frame = 1024
$rdw_internalpaint = 2
$rdw_invalidate = 1
$rdw_noerase = 32
$rdw_noframe = 2048
$rdw_nointernalpaint = 16
$rdw_validate = 8
$rdw_erasenow = 512
$rdw_updatenow = 256
$rdw_allchildren = 128
$rdw_nochildren = 64
$wm_renderformat = 773
$wm_renderallformats = 774
$wm_destroyclipboard = 775
$wm_drawclipboard = 776
$wm_paintclipboard = 777
$wm_vscrollclipboard = 778
$wm_sizeclipboard = 779
$wm_askcbformatname = 780
$wm_changecbchain = 781
$wm_hscrollclipboard = 782
$hterror = -2
$httransparent = -1
$htnowhere = 0
$htclient = 1
$htcaption = 2
$htsysmenu = 3
$htgrowbox = 4
$htsize = $htgrowbox
$htmenu = 5
$hthscroll = 6
$htvscroll = 7
$htminbutton = 8
$htmaxbutton = 9
$htleft = 10
$htright = 11
$httop = 12
$httopleft = 13
$httopright = 14
$htbottom = 15
$htbottomleft = 16
$htbottomright = 17
$htborder = 18
$htreduce = $htminbutton
$htzoom = $htmaxbutton
$htsizefirst = $htleft
$htsizelast = $htbottomright
$htobject = 19
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$htclose = 20
$hthelp = 21
$color_scrollbar = 0
$color_background = 1
$color_activecaption = 2
$color_inactivecaption = 3
$color_menu = 4
$color_window = 5
$color_windowframe = 6
$color_menutext = 7
$color_windowtext = 8
$color_captiontext = 9
$color_activeborder = 10
$color_inactiveborder = 11
$color_appworkspace = 12
$color_highlight = 13
$color_highlighttext = 14
$color_btnface = 15
$color_btnshadow = 16
$color_graytext = 17
$color_btntext = 18
$color_inactivecaptiontext = 19
$color_btnhighlight = 20
$color_3ddkshadow = 21
$color_3dlight = 22
$color_infotext = 23
$color_infobk = 24
$color_hotlight = 26
$color_gradientactivecaption = 27
$color_gradientinactivecaption = 28
$color_menuhilight = 29
$color_menubar = 30
$color_desktop = 1
$color_3dface = 15
$color_3dshadow = 16
$color_3dhighlight = 20
$color_3dhilight = 20
$color_btnhilight = 20
$hinst_commctrl = -1
$idb_std_small_color = 0
$idb_std_large_color = 1
$idb_view_small_color = 4
$idb_view_large_color = 5
$idb_hist_small_color = 8
$idb_hist_large_color = 9
$startf_forceofffeedback = 128
$startf_forceonfeedback = 64
$startf_preventpinning = 8192
$startf_runfullscreen = 32
$startf_titleisappid = 4096
$startf_titleislinkname = 2048
$startf_usecountchars = 8
$startf_usefillattribute = 16
$startf_usehotkey = 512
$startf_useposition = 4
$startf_useshowwindow = 1
$startf_usesize = 2
$startf_usestdhandles = 256
$cdds_prepaint = 1
$cdds_postpaint = 2
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$page_nocache = 512
$page_writecombine = 1024
$page_writecopy = 8
$mem_decommit = 16384
$mem_release = 32768
$process_terminate = 1
$process_create_thread = 2
$process_set_sessionid = 4
$process_vm_operation = 8
$process_vm_read = 16
$process_vm_write = 32
$process_dup_handle = 64
$process_create_process = 128
$process_set_quota = 256
$process_set_information = 512
$process_query_information = 1024
$process_query_limited_information = 4096
$process_suspend_resume = 2048
$process_all_access = 2035711
$se_assignprimarytoken_name = "SeAssignPrimaryTokenPrivileg
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
$se_audit_name = "SeAuditPrivilege"
$se_backup_name = "SeBackupPrivilege"
$se_change_notify_name = "SeChangeNotifyPrivilege"
$se_create_global_name = "SeCreateGlobalPrivilege"
$se_create_pagefile_name = "SeCreatePagefilePrivilege"
$se_create_permanent_name = "SeCreatePermanentPrivilege"
$se_create_symbolic_link_name = "SeCreateSymbolicLinkPrivil
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
$se_create_token_name = "SeCreateTokenPrivilege"
$se_debug_name = "SeDebugPrivilege"
$se_enable_delegation_name = "SeEnableDelegationPrivilege"
$se_impersonate_name = "SeImpersonatePrivilege"
$se_inc_base_priority_name = "SeIncreaseBasePriorityPrivile
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
$se_inc_working_set_name = "SeIncreaseWorkingSetPrivilege"
$se_increase_quota_name = "SeIncreaseQuotaPrivilege"
$se_load_driver_name = "SeLoadDriverPrivilege"
$se_lock_memory_name = "SeLockMemoryPrivilege"
$se_machine_account_name = "SeMachineAccountPrivilege"
$se_manage_volume_name = "SeManageVolumePrivilege"
$se_prof_single_process_name = "SeProfileSingleProcessPrivi
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
$se_relabel_name = "SeRelabelPrivilege"
$se_remote_shutdown_name = "SeRemoteShutdownPrivilege"
$se_restore_name = "SeRestorePrivilege"
$se_security_name = "SeSecurityPrivilege"
$se_shutdown_name = "SeShutdownPrivilege"
$se_sync_agent_name = "SeSyncAgentPrivilege"
$se_system_environment_name = "SeSystemEnvironmentPrivilege
Global
Global
Global
Global
Global
Global
ivilege"
Global
Global
Const
Const
Const
Const
Const
Const
$se_system_profile_name = "SeSystemProfilePrivilege"
$se_systemtime_name = "SeSystemtimePrivilege"
$se_take_ownership_name = "SeTakeOwnershipPrivilege"
$se_tcb_name = "SeTcbPrivilege"
$se_time_zone_name = "SeTimeZonePrivilege"
$se_trusted_credman_access_name = "SeTrustedCredManAccessPr
e"
ege"
ge"
lege"
"
AB & "= " & $ocomerror.lastdllerror & @CRLF & $sprefix & "Retcode
& "= 0x" & Hex($ocomerror.retcode)
Return $serror
EndFunc
0])
Return ""
Func _security__getlengthsid($psid)
If NOT _security__isvalidsid($psid) Then Return SetError(@error
+ 10, @extended, 0)
Local $acall = DllCall("advapi32.dll", "dword", "GetLengthSid",
"struct*", $psid)
If @error Then Return SetError(@error, @extended, 0)
Return $acall[0]
EndFunc
Func _security__gettokeninformation($htoken, $iclass)
Local $acall = DllCall("advapi32.dll", "bool", "GetTokenInformat
ion", "handle", $htoken, "int", $iclass, "struct*", 0, "dword", 0, "dword*", 0)
If @error OR NOT $acall[5] Then Return SetError(@error + 10, @ex
tended, 0)
Local $ilen = $acall[5]
Local $tbuffer = DllStructCreate("byte[" & $ilen & "]")
$acall = DllCall("advapi32.dll", "bool", "GetTokenInformation",
urrentThread")
If $hthread = 0 Then
Local $aresult = DllCall("kernel32.dll", "handle", "GetC
If @error Then Return SetError(@error + 10, @extended, 0
$hthread = $aresult[0]
EndIf
Local $acall = DllCall("advapi32.dll", "bool", "OpenThreadToken"
, "handle", $hthread, "dword", $iaccess, "bool", $bopenasself, "handle*", 0)
If @error OR NOT $acall[0] Then Return SetError(@error, @extende
d, 0)
Return $acall[4]
EndFunc
False)
bopenasself)
If $htoken = 0 Then
Local Const $error_no_token = 1008
If _winapi_getlasterror() <> $error_no_token Then Return
SetError(20, _winapi_getlasterror(), 0)
If NOT _security__impersonateself() Then Return SetError
(@error + 10, _winapi_getlasterror(), 0)
$htoken = _security__openthreadtoken($iaccess, $hthread,
$bopenasself)
If $htoken = 0 Then Return SetError(@error, _winapi_getl
asterror(), 0)
EndIf
Return $htoken
EndFunc
Local
ID;dword Attributes"
Local
Local
Local
Local
Local
DllStructSetData($tcurrstate, "Count", 1)
DllStructSetData($tcurrstate, "LUID", $iluid)
If NOT _security__adjusttokenprivileges($htoken, False, $tcurrst
ate, $icurrstate, $tprevstate, $trequired) Then Return SetError(2, @error, False
)
DllStructSetData($tprevstate, "Count", 1)
DllStructSetData($tprevstate, "LUID", $iluid)
Local $iattributes = DllStructGetData($tprevstate, "Attributes")
If $benable Then
$iattributes = BitOR($iattributes, $se_privilege_enabled
)
Else
$iattributes = BitAND($iattributes, BitNOT($se_privilege
_enabled))
EndIf
DllStructSetData($tprevstate, "Attributes", $iattributes)
If NOT _security__adjusttokenprivileges($htoken, False, $tprevst
ate, $iprevstate, $tcurrstate, $trequired) Then Return SetError(3, @error, False
)
Return True
EndFunc
Func _security__settokeninformation($htoken, $itokeninformation, $vtoken
information, $itokeninformationlength)
Local $acall = DllCall("advapi32.dll", "bool", "SetTokenInformat
ion", "handle", $htoken, "int", $itokeninformation, "struct*", $vtokeninformatio
n, "dword", $itokeninformationlength)
If @error OR NOT $acall[0] Then Return SetError(@error, @extende
d, False)
Return True
EndFunc
Func _security__sidtostringsid($psid)
If NOT _security__isvalidsid($psid) Then Return SetError(@error
+ 10, 0, "")
Local $acall = DllCall("advapi32.dll", "bool", "ConvertSidToStri
ngSidW", "struct*", $psid, "ptr*", 0)
If @error OR NOT $acall[0] Then Return SetError(@error, @extende
d, "")
Local $pstringsid = $acall[2]
Local $alen = DllCall("kernel32.dll", "int", "lstrlenW", "struct
*", $pstringsid)
Local $ssid = DllStructGetData(DllStructCreate("wchar Text[" & $
alen[0] + 1 & "]", $pstringsid), "Text")
DllCall("kernel32.dll", "handle", "LocalFree", "handle", $pstrin
gsid)
Return $ssid
EndFunc
Func _security__sidtypestr($itype)
Switch $itype
Case $sidtypeuser
Return "User"
Case $sidtypegroup
Return "Group"
Case $sidtypedomain
Return "Domain"
Case $sidtypealias
Return "Alias"
Case $sidtypewellknowngroup
EndFunc
Func _security__stringsidtosid($ssid)
Local $acall = DllCall("advapi32.dll", "bool", "ConvertStringSid
ToSidW", "wstr", $ssid, "ptr*", 0)
If @error OR NOT $acall[0] Then Return SetError(@error, @extende
d, 0)
Local $psid = $acall[2]
Local $tbuffer = DllStructCreate("byte Data[" & _security__getle
ngthsid($psid) & "]", $psid)
Local $tsid = DllStructCreate("byte Data[" & DllStructGetSize($t
buffer) & "]")
DllStructSetData($tsid, "Data", DllStructGetData($tbuffer, "Data
"))
DllCall("kernel32.dll", "handle", "LocalFree", "handle", $psid)
Return $tsid
EndFunc
Global Const $tagpoint = "struct;long X;long Y;endstruct"
Global Const $tagrect = "struct;long Left;long Top;long Right;long Botto
m;endstruct"
Global Const $tagsize = "struct;long X;long Y;endstruct"
Global Const $tagmargins = "int cxLeftWidth;int cxRightWidth;int cyTopHe
ight;int cyBottomHeight"
Global Const $tagfiletime = "struct;dword Lo;dword Hi;endstruct"
Global Const $tagsystemtime = "struct;word Year;word Month;word Dow;word
Day;word Hour;word Minute;word Second;word MSeconds;endstruct"
Global Const $tagtime_zone_information = "struct;long Bias;wchar StdName
[32];word StdDate[8];long StdBias;wchar DayName[32];word DayDate[8];long DayBias
;endstruct"
Global Const $tagnmhdr = "struct;hwnd hWndFrom;uint_ptr IDFrom;INT Code;
endstruct"
Global Const $tagcomboboxexitem = "uint Mask;int_ptr Item;ptr Text;int T
extMax;int Image;int SelectedImage;int OverlayImage;" & "int Indent;lparam Param
"
Global Const $tagnmcbedragbegin = $tagnmhdr & ";int ItemID;wchar szText[
260]"
Global Const $tagnmcbeendedit = $tagnmhdr & ";bool fChanged;int NewSelec
tion;wchar szText[260];int Why"
Global Const $tagnmcomboboxex = $tagnmhdr & ";uint Mask;int_ptr Item;ptr
Text;int TextMax;int Image;" & "int SelectedImage;int OverlayImage;int Indent;l
param Param"
Global Const $tagdtprange = "word MinYear;word MinMonth;word MinDOW;word
MinDay;word MinHour;word MinMinute;" & "word MinSecond;word MinMSecond;word Max
Year;word MaxMonth;word MaxDOW;word MaxDay;word MaxHour;" & "word MaxMinute;word
MaxSecond;word MaxMSecond;bool MinValid;bool MaxValid"
temtime
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$opt_coordsrelative = 0
$opt_coordsabsolute = 1
$opt_coordsclient = 2
$opt_errorsilent = 0
$opt_errorfatal = 1
$opt_capsnostore = 0
$opt_capsstore = 1
$opt_matchstart = 1
$opt_matchany = 2
$opt_matchexact = 3
$opt_matchadvanced = 4
$ccs_top = 1
$ccs_nomovey = 2
$ccs_bottom = 3
$ccs_noresize = 4
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$ccs_noparentalign = 8
$ccs_nohilite = 16
$ccs_adjustable = 32
$ccs_nodivider = 64
$ccs_vert = 128
$ccs_left = 129
$ccs_nomovex = 130
$ccs_right = 131
$dt_drivetype = 1
$dt_ssdstatus = 2
$dt_bustype = 3
$proxy_ie = 0
$proxy_none = 1
$proxy_specified = 2
$objid_window = 0
$objid_titlebar = -2
$objid_sizegrip = -7
$objid_caret = -8
$objid_cursor = -9
$objid_alert = -10
$objid_sound = -11
$dlg_centerontop = 0
$dlg_notitle = 1
$dlg_notontop = 2
$dlg_textleft = 4
$dlg_textright = 8
$dlg_moveable = 16
$dlg_textvcenter = 32
$idc_unknown = 0
$idc_appstarting = 1
$idc_arrow = 2
$idc_cross = 3
$idc_hand = 32649
$idc_help = 4
$idc_ibeam = 5
$idc_icon = 6
$idc_no = 7
$idc_size = 8
$idc_sizeall = 9
$idc_sizenesw = 10
$idc_sizens = 11
$idc_sizenwse = 12
$idc_sizewe = 13
$idc_uparrow = 14
$idc_wait = 15
$idi_application = 32512
$idi_asterisk = 32516
$idi_exclamation = 32515
$idi_hand = 32513
$idi_question = 32514
$idi_winlogo = 32517
$idi_shield = 32518
$idi_error = $idi_hand
$idi_information = $idi_asterisk
$idi_warning = $idi_exclamation
$sd_logoff = 0
$sd_shutdown = 1
$sd_reboot = 2
$sd_force = 4
$sd_powerdown = 8
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$sd_forcehung = 16
$sd_standby = 32
$sd_hibernate = 64
$stdin_child = 1
$stdout_child = 2
$stderr_child = 4
$stderr_merged = 8
$stdio_inherit_parent = 16
$run_create_new_console = 65536
$ubound_dimensions = 0
$ubound_rows = 1
$ubound_columns = 2
$mouseeventf_absolute = 32768
$mouseeventf_move = 1
$mouseeventf_leftdown = 2
$mouseeventf_leftup = 4
$mouseeventf_rightdown = 8
$mouseeventf_rightup = 16
$mouseeventf_middledown = 32
$mouseeventf_middleup = 64
$mouseeventf_wheel = 2048
$mouseeventf_xdown = 128
$mouseeventf_xup = 256
$reg_none = 0
$reg_sz = 1
$reg_expand_sz = 2
$reg_binary = 3
$reg_dword = 4
$reg_dword_little_endian = 4
$reg_dword_big_endian = 5
$reg_link = 6
$reg_multi_sz = 7
$reg_resource_list = 8
$reg_full_resource_descriptor = 9
$reg_resource_requirements_list = 10
$reg_qword = 11
$reg_qword_little_endian = 11
$hwnd_bottom = 1
$hwnd_notopmost = -2
$hwnd_top = 0
$hwnd_topmost = -1
$swp_nosize = 1
$swp_nomove = 2
$swp_nozorder = 4
$swp_noredraw = 8
$swp_noactivate = 16
$swp_framechanged = 32
$swp_drawframe = 32
$swp_showwindow = 64
$swp_hidewindow = 128
$swp_nocopybits = 256
$swp_noownerzorder = 512
$swp_noreposition = 512
$swp_nosendchanging = 1024
$swp_defererase = 8192
$swp_asyncwindowpos = 16384
$keyword_default = 1
$keyword_null = 2
$declared_local = -1
$declared_unknown = 0
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$declared_global = 1
$assign_create = 0
$assign_forcelocal = 1
$assign_forceglobal = 2
$assign_existfail = 4
$bi_enable = 0
$bi_disable = 1
$break_enable = 1
$break_disable = 0
$cdtray_open = "open"
$cdtray_closed = "closed"
$send_default = 0
$send_raw = 1
$dir_default = 0
$dir_extended = 1
$dir_norecurse = 2
$dir_remove = 1
$dt_all = "ALL"
$dt_cdrom = "CDROM"
$dt_removable = "REMOVABLE"
$dt_fixed = "FIXED"
$dt_network = "NETWORK"
$dt_ramdisk = "RAMDISK"
$dt_unknown = "UNKNOWN"
$dt_undefined = 1
$dt_fat = "FAT"
$dt_fat32 = "FAT32"
$dt_exfat = "exFAT"
$dt_ntfs = "NTFS"
$dt_nwfs = "NWFS"
$dt_cdfs = "CDFS"
$dt_udf = "UDF"
$dma_default = 0
$dma_persistent = 1
$dma_authentication = 8
$ds_unknown = "UNKNOWN"
$ds_ready = "READY"
$ds_notready = "NOTREADY"
$ds_invalid = "INVALID"
$mouse_click_left = "left"
$mouse_click_right = "right"
$mouse_click_middle = "middle"
$mouse_click_main = "main"
$mouse_click_menu = "menu"
$mouse_click_primary = "primary"
$mouse_click_secondary = "secondary"
$mouse_wheel_up = "up"
$mouse_wheel_down = "down"
$number_auto = 0
$number_32bit = 1
$number_64bit = 2
$number_double = 3
$obj_name = 1
$obj_string = 2
$obj_progid = 3
$obj_file = 4
$obj_module = 5
$obj_clsid = 6
$obj_iid = 7
$exitclose_normal = 0
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$exitclose_byexit = 1
$exitclose_byclick = 2
$exitclose_bylogoff = 3
$exitclose_bysutdown = 4
$process_stats_memory = 0
$process_stats_io = 1
$process_low = 0
$process_belownormal = 1
$process_normal = 2
$process_abovenormal = 3
$process_high = 4
$process_realtime = 5
$run_logon_noprofile = 0
$run_logon_profile = 1
$run_logon_network = 2
$run_logon_inherit = 4
$sound_nowait = 0
$sound_wait = 1
$shex_open = "open"
$shex_edit = "edit"
$shex_print = "print"
$shex_properties = "properties"
$tcp_data_default = 0
$tcp_data_binary = 1
$udp_open_default = 0
$udp_open_broadcast = 1
$udp_data_default = 0
$udp_data_binary = 1
$udp_data_array = 2
$tip_noicon = 0
$tip_infoicon = 1
$tip_warningicon = 2
$tip_erroricon = 3
$tip_balloon = 1
$tip_center = 2
$tip_forcevisible = 4
$windows_noontop = 0
$windows_ontop = 1
$fc_nooverwrite = 0
$fc_overwrite = 1
$fc_createpath = 8
$ft_modified = 0
$ft_created = 1
$ft_accessed = 2
$ft_array = 0
$ft_string = 1
$fsf_createbutton = 1
$fsf_newdialog = 2
$fsf_editcontrol = 4
$ft_nonrecursive = 0
$ft_recursive = 1
$fo_read = 0
$fo_append = 1
$fo_overwrite = 2
$fo_createpath = 8
$fo_binary = 16
$fo_unicode = 32
$fo_utf16_le = 32
$fo_utf16_be = 64
$fo_utf8 = 128
_write)
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$fo_utf8_nobom = 256
$fo_ansi = 512
$fo_utf16_le_nobom = 1024
$fo_utf16_be_nobom = 2048
$fo_utf8_full = 16384
$fo_fullfile_detect = 16384
$eof = -1
$fd_filemustexist = 1
$fd_pathmustexist = 2
$fd_multiselect = 4
$fd_promptcreatenew = 8
$fd_promptoverwrite = 16
$create_new = 1
$create_always = 2
$open_existing = 3
$open_always = 4
$truncate_existing = 5
$invalid_set_file_pointer = -1
$file_begin = 0
$file_current = 1
$file_end = 2
$file_attribute_readonly = 1
$file_attribute_hidden = 2
$file_attribute_system = 4
$file_attribute_directory = 16
$file_attribute_archive = 32
$file_attribute_device = 64
$file_attribute_normal = 128
$file_attribute_temporary = 256
$file_attribute_sparse_file = 512
$file_attribute_reparse_point = 1024
$file_attribute_compressed = 2048
$file_attribute_offline = 4096
$file_attribute_not_content_indexed = 8192
$file_attribute_encrypted = 16384
$file_share_read = 1
$file_share_write = 2
$file_share_delete = 4
$file_share_readwrite = BitOR($file_share_read, $file_share
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$fv_productname = "ProductName"
$fv_productversion = "ProductVersion"
$fv_privatebuild = "PrivateBuild"
$fv_specialbuild = "SpecialBuild"
$frta_nocount = 0
$frta_count = 1
$frta_intarrays = 2
$frta_entiresplit = 4
$flta_filesfolders = 0
$flta_files = 1
$flta_folders = 2
$fltar_filesfolders = 0
$fltar_files = 1
$fltar_folders = 2
$fltar_nohidden = 4
$fltar_nosystem = 8
$fltar_nolink = 16
$fltar_norecur = 0
$fltar_recur = 1
$fltar_nosort = 0
$fltar_sort = 1
$fltar_fastsort = 2
$fltar_nopath = 0
$fltar_relpath = 1
$fltar_fullpath = 2
$mb_ok = 0
$mb_okcancel = 1
$mb_abortretryignore = 2
$mb_yesnocancel = 3
$mb_yesno = 4
$mb_retrycancel = 5
$mb_canceltrycontinue = 6
$mb_help = 16384
$mb_iconstop = 16
$mb_iconerror = 16
$mb_iconhand = 16
$mb_iconquestion = 32
$mb_iconexclamation = 48
$mb_iconwarning = 48
$mb_iconinformation = 64
$mb_iconasterisk = 64
$mb_usericon = 128
$mb_defbutton1 = 0
$mb_defbutton2 = 256
$mb_defbutton3 = 512
$mb_defbutton4 = 768
$mb_applmodal = 0
$mb_systemmodal = 4096
$mb_taskmodal = 8192
$mb_default_desktop_only = 131072
$mb_right = 524288
$mb_rtlreading = 1048576
$mb_setforeground = 65536
$mb_topmost = 262144
$mb_service_notification = 2097152
$mb_rightjustified = $mb_right
$idtimeout = -1
$idok = 1
$idcancel = 2
$idabort = 3
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$idretry = 4
$idignore = 5
$idyes = 6
$idno = 7
$idclose = 8
$idhelp = 9
$idtryagain = 10
$idcontinue = 11
$str_nocasesense = 0
$str_casesense = 1
$str_nocasesensebasic = 2
$str_stripleading = 1
$str_striptrailing = 2
$str_stripspaces = 4
$str_stripall = 8
$str_chrsplit = 0
$str_entiresplit = 1
$str_nocount = 2
$str_regexpmatch = 0
$str_regexparraymatch = 1
$str_regexparrayfullmatch = 2
$str_regexparrayglobalmatch = 3
$str_regexparrayglobalfullmatch = 4
$str_endisstart = 0
$str_endnotstart = 1
$sb_ansi = 1
$sb_utf16le = 2
$sb_utf16be = 3
$sb_utf8 = 4
$se_utf16 = 0
$se_ansi = 1
$se_utf8 = 2
$str_utf16 = 0
$str_ucs2 = 1
$hgdi_error = Ptr(-1)
$invalid_handle_value = Ptr(-1)
$clr_invalid = -1
$null_brush = 5
$null_pen = 8
$black_brush = 4
$dkgray_brush = 3
$dc_brush = 18
$gray_brush = 2
$hollow_brush = $null_brush
$ltgray_brush = 1
$white_brush = 0
$black_pen = 7
$dc_pen = 19
$white_pen = 6
$ansi_fixed_font = 11
$ansi_var_font = 12
$device_default_font = 14
$default_gui_font = 17
$oem_fixed_font = 10
$system_font = 13
$system_fixed_font = 16
$default_palette = 15
$mb_precomposed = 1
$mb_composite = 2
$mb_useglyphchars = 4
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$ulw_alpha = 2
$ulw_colorkey = 1
$ulw_opaque = 4
$ulw_ex_noresize = 8
$wh_callwndproc = 4
$wh_callwndprocret = 12
$wh_cbt = 5
$wh_debug = 9
$wh_foregroundidle = 11
$wh_getmessage = 3
$wh_journalplayback = 1
$wh_journalrecord = 0
$wh_keyboard = 2
$wh_keyboard_ll = 13
$wh_mouse = 7
$wh_mouse_ll = 14
$wh_msgfilter = -1
$wh_shell = 10
$wh_sysmsgfilter = 6
$wpf_asyncwindowplacement = 4
$wpf_restoretomaximized = 2
$wpf_setminposition = 1
$kf_extended = 256
$kf_altdown = 8192
$kf_up = 32768
$llkhf_extended = BitShift($kf_extended, 8)
$llkhf_injected = 16
$llkhf_altdown = BitShift($kf_altdown, 8)
$llkhf_up = BitShift($kf_up, 8)
$ofn_allowmultiselect = 512
$ofn_createprompt = 8192
$ofn_dontaddtorecent = 33554432
$ofn_enablehook = 32
$ofn_enableincludenotify = 4194304
$ofn_enablesizing = 8388608
$ofn_enabletemplate = 64
$ofn_enabletemplatehandle = 128
$ofn_explorer = 524288
$ofn_extensiondifferent = 1024
$ofn_filemustexist = 4096
$ofn_forceshowhidden = 268435456
$ofn_hidereadonly = 4
$ofn_longnames = 2097152
$ofn_nochangedir = 8
$ofn_nodereferencelinks = 1048576
$ofn_nolongnames = 262144
$ofn_nonetworkbutton = 131072
$ofn_noreadonlyreturn = 32768
$ofn_notestfilecreate = 65536
$ofn_novalidate = 256
$ofn_overwriteprompt = 2
$ofn_pathmustexist = 2048
$ofn_readonly = 1
$ofn_shareaware = 16384
$ofn_showhelp = 16
$ofn_ex_noplacesbar = 1
$tmpf_fixed_pitch = 1
$tmpf_vector = 2
$tmpf_truetype = 4
$tmpf_device = 8
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$duplicate_close_source = 1
$duplicate_same_access = 2
$di_mask = 1
$di_image = 2
$di_normal = 3
$di_compat = 4
$di_defaultsize = 8
$di_nomirror = 16
$display_device_attached_to_desktop = 1
$display_device_multi_driver = 2
$display_device_primary_device = 4
$display_device_mirroring_driver = 8
$display_device_vga_compatible = 16
$display_device_removable = 32
$display_device_disconnect = 33554432
$display_device_remote = 67108864
$display_device_modespruned = 134217728
$flashw_caption = 1
$flashw_tray = 2
$flashw_timer = 4
$flashw_timernofg = 12
$format_message_allocate_buffer = 256
$format_message_ignore_inserts = 512
$format_message_from_string = 1024
$format_message_from_hmodule = 2048
$format_message_from_system = 4096
$format_message_argument_array = 8192
$gw_hwndfirst = 0
$gw_hwndlast = 1
$gw_hwndnext = 2
$gw_hwndprev = 3
$gw_owner = 4
$gw_child = 5
$gw_enabledpopup = 6
$gwl_wndproc = -4
$gwl_hinstance = -6
$gwl_hwndparent = -8
$gwl_id = -12
$gwl_style = -16
$gwl_exstyle = -20
$gwl_userdata = -21
$std_cut = 0
$std_copy = 1
$std_paste = 2
$std_undo = 3
$std_redow = 4
$std_delete = 5
$std_filenew = 6
$std_fileopen = 7
$std_filesave = 8
$std_printpre = 9
$std_properties = 10
$std_help = 11
$std_find = 12
$std_replace = 13
$std_print = 14
$image_bitmap = 0
$image_icon = 1
$image_cursor = 2
$image_enhmetafile = 3
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$kb_sendspecial = 0
$kb_sendraw = 1
$kb_capsoff = 0
$kb_capson = 1
$dont_resolve_dll_references = 1
$load_library_as_datafile = 2
$load_with_altered_search_path = 8
$load_ignore_code_authz_level = 16
$load_library_as_datafile_exclusive = 64
$load_library_as_image_resource = 32
$load_library_search_application_dir = 512
$load_library_search_default_dirs = 4096
$load_library_search_dll_load_dir = 256
$load_library_search_system32 = 2048
$load_library_search_user_dirs = 1024
$s_ok = 0
$e_abort = -2147467260
$e_accessdenied = -2147024891
$e_fail = -2147467259
$e_handle = -2147024890
$e_invalidarg = -2147024809
$e_nointerface = -2147467262
$e_notimpl = -2147467263
$e_outofmemory = -2147024882
$e_pointer = -2147467261
$e_unexpected = -2147418113
$lr_defaultcolor = 0
$lr_monochrome = 1
$lr_color = 2
$lr_copyreturnorg = 4
$lr_copydeleteorg = 8
$lr_loadfromfile = 16
$lr_loadtransparent = 32
$lr_defaultsize = 64
$lr_vgacolor = 128
$lr_loadmap3dcolors = 4096
$lr_createdibsection = 8192
$lr_copyfromresource = 16384
$lr_shared = 32768
$obm_trtype = 32732
$obm_lfarrowi = 32734
$obm_rgarrowi = 32735
$obm_dnarrowi = 32736
$obm_uparrowi = 32737
$obm_combo = 32738
$obm_mnarrow = 32739
$obm_lfarrowd = 32740
$obm_rgarrowd = 32741
$obm_dnarrowd = 32742
$obm_uparrowd = 32743
$obm_restored = 32744
$obm_zoomd = 32745
$obm_reduced = 32746
$obm_restore = 32747
$obm_zoom = 32748
$obm_reduce = 32749
$obm_lfarrow = 32750
$obm_rgarrow = 32751
$obm_dnarrow = 32752
$obm_uparrow = 32753
edError")
Local
Local
Local
Local
Local
Local
Local
Local
Local
Local
Local
Const $cderr_memallocfailure = 9
Const $cderr_memlockfailure = 10
Const $cderr_nohinstance = 4
Const $cderr_nohook = 11
Const $cderr_notemplate = 3
Const $cderr_registermsgfail = 12
Const $cderr_structsize = 1
Const $fnerr_buffertoosmall = 12291
Const $fnerr_invalidfilename = 12290
Const $fnerr_subclassfailure = 12289
$aresult = DllCall("comdlg32.dll", "dword", "CommDlgExtend
Case $cderr_structsize
Return SetError($aresult[0], 0, "The lSt
ructSize member of the initialization structure for the corresponding common dia
log box is invalid")
Case $fnerr_buffertoosmall
Return SetError($aresult[0], 0, "The buf
fer pointed to by the lpstrFile member of the OPENFILENAME structure is too smal
l for the file name specified by the user." & @LF & "The first two bytes of the
lpstrFile buffer contain an integer value specifying the size, in TCHARs, requir
ed to receive the full name.")
Case $fnerr_invalidfilename
Return SetError($aresult[0], 0, "A file
name is invalid.")
Case $fnerr_subclassfailure
Return SetError($aresult[0], 0, "An atte
mpt to subclass a list box failed because sufficient memory was not available.")
EndSwitch
EndIf
Return SetError(@error, @extended, "0x" & Hex($aresult[0]))
EndFunc
Func _winapi_copyicon($hicon)
Local $aresult = DllCall("user32.dll", "handle", "CopyIcon", "ha
ndle", $hicon)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_createbitmap($iwidth, $iheight, $iplanes = 1, $ibitsperpel
= 1, $pbits = 0)
Local $aresult = DllCall("gdi32.dll", "handle", "CreateBitmap",
"int", $iwidth, "int", $iheight, "uint", $iplanes, "uint", $ibitsperpel, "struct
*", $pbits)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_createcompatiblebitmap($hdc, $iwidth, $iheight)
Local $aresult = DllCall("gdi32.dll", "handle", "CreateCompatibl
eBitmap", "handle", $hdc, "int", $iwidth, "int", $iheight)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_createcompatibledc($hdc)
Local $aresult = DllCall("gdi32.dll", "handle", "CreateCompatibl
eDC", "handle", $hdc)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_createevent($tattributes = 0, $bmanualreset = True, $biniti
alstate = True, $sname = "")
Local $snametype = "wstr"
If $sname = "" Then
$sname = 0
$snametype = "ptr"
EndIf
Local $aresult = DllCall("kernel32.dll", "handle", "CreateEventW
EndFunc
Func _winapi_createfontindirect($tlogfont)
Local $aresult = DllCall("gdi32.dll", "handle", "CreateFontIndir
ectW", "struct*", $tlogfont)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_createpen($ipenstyle, $iwidth, $icolor)
Local $aresult = DllCall("gdi32.dll", "handle", "CreatePen", "in
t", $ipenstyle, "int", $iwidth, "INT", $icolor)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_createprocess($sappname, $scommand, $tsecurity, $tthread, $
binherit, $iflags, $penviron, $sdir, $tstartupinfo, $tprocess)
Local $tcommand = 0
Local $sappnametype = "wstr", $sdirtype = "wstr"
If $sappname = "" Then
$sappnametype = "ptr"
$sappname = 0
EndIf
If $scommand <> "" Then
$tcommand = DllStructCreate("wchar Text[" & 260 + 1 & "]
")
DllStructSetData($tcommand, "Text", $scommand)
EndIf
If $sdir = "" Then
$sdirtype = "ptr"
$sdir = 0
EndIf
Local $aresult = DllCall("kernel32.dll", "bool", "CreateProcessW
", $sappnametype, $sappname, "struct*", $tcommand, "struct*", $tsecurity, "struc
t*", $tthread, "bool", $binherit, "dword", $iflags, "struct*", $penviron, $sdirt
ype, $sdir, "struct*", $tstartupinfo, "struct*", $tprocess)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
ect)
= 1)
iheight)
Func _winapi_deleteobject($hobject)
Local $aresult = DllCall("gdi32.dll", "bool", "DeleteObject", "h
andle", $hobject)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_destroyicon($hicon)
Local $aresult = DllCall("user32.dll", "bool", "DestroyIcon", "h
andle", $hicon)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_destroywindow($hwnd)
Local $aresult = DllCall("user32.dll", "bool", "DestroyWindow",
"hwnd", $hwnd)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_drawedge($hdc, $trect, $iedgetype, $iflags)
Local $aresult = DllCall("user32.dll", "bool", "DrawEdge", "hand
le", $hdc, "struct*", $trect, "uint", $iedgetype, "uint", $iflags)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_drawframecontrol($hdc, $trect, $itype, $istate)
Local $aresult = DllCall("user32.dll", "bool", "DrawFrameControl
", "handle", $hdc, "struct*", $trect, "uint", $itype, "uint", $istate)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_drawicon($hdc, $ix, $iy, $hicon)
Local $aresult = DllCall("user32.dll", "bool", "DrawIcon", "hand
le", $hdc, "int", $ix, "int", $iy, "handle", $hicon)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_drawiconex($hdc, $ix, $iy, $hicon, $iwidth = 0, $iheight =
0, $istep = 0, $hbrush = 0, $iflags = 3)
Local $ioptions
Switch $iflags
Case 1
$ioptions = $di_mask
Case 2
$ioptions = $di_image
Case 3
$ioptions = $di_normal
Case 4
$ioptions = $di_compat
Case 5
$ioptions = $di_defaultsize
Case Else
$ioptions = $di_nomirror
EndSwitch
gs = BitOR($iflags, 4)
If BitAND($in, $display_device_vga_compatible) <> 0 Then $iflags
= BitOR($iflags, 8)
If BitAND($in, $display_device_removable) <> 0 Then $iflags = Bi
tOR($iflags, 16)
If BitAND($in, $display_device_modespruned) <> 0 Then $iflags =
BitOR($iflags, 32)
$adevice[0] = True
$adevice[1] = DllStructGetData($tdevice, "Name")
$adevice[2] = DllStructGetData($tdevice, "String")
$adevice[3] = $iflags
$adevice[4] = DllStructGetData($tdevice, "ID")
Return $adevice
EndFunc
Func _winapi_enumwindows($bvisible = True, $hwnd = Default)
__winapi_enumwindowsinit()
If $hwnd = Default Then $hwnd = _winapi_getdesktopwindow()
__winapi_enumwindowschild($hwnd, $bvisible)
Return $__g_awinlist_winapi
EndFunc
Func __winapi_enumwindowsadd($hwnd, $sclass = "")
If $sclass = "" Then $sclass = _winapi_getclassname($hwnd)
$__g_awinlist_winapi[0][0] += 1
Local $icount = $__g_awinlist_winapi[0][0]
If $icount >= $__g_awinlist_winapi[0][1] Then
ReDim $__g_awinlist_winapi[$icount + 64][2]
$__g_awinlist_winapi[0][1] += 64
EndIf
$__g_awinlist_winapi[$icount][0] = $hwnd
$__g_awinlist_winapi[$icount][1] = $sclass
EndFunc
EndFunc
WEnd
EndIf
$hwnd = _winapi_getwindow($hwnd, $gw_hwndnext)
Func __winapi_enumwindowsinit()
ReDim $__g_awinlist_winapi[64][2]
$__g_awinlist_winapi[0][0] = 0
$__g_awinlist_winapi[0][1] = 64
EndFunc
child)
Func _winapi_enumwindowspopup()
__winapi_enumwindowsinit()
Local $hwnd = _winapi_getwindow(_winapi_getdesktopwindow(), $gw_
Local $sclass
While $hwnd <> 0
If _winapi_iswindowvisible($hwnd) Then
$sclass = _winapi_getclassname($hwnd)
EndIf
$hwnd = _winapi_getwindow($hwnd, $gw_hwndnext)
EndFunc
child)
WEnd
Return $__g_awinlist_winapi
Func _winapi_enumwindowstop()
__winapi_enumwindowsinit()
Local $hwnd = _winapi_getwindow(_winapi_getdesktopwindow(), $gw_
owsadd($hwnd)
EndFunc
Func _winapi_expandenvironmentstrings($sstring)
Local $aresult = DllCall("kernel32.dll", "dword", "ExpandEnviron
mentStringsW", "wstr", $sstring, "wstr", "", "dword", 4096)
If @error OR NOT $aresult[0] Then Return SetError(@error + 10, @
extended, "")
Return $aresult[2]
EndFunc
ons)
EndFunc
Return $aresult[0]
aption)
ray)
imer)
imernofg)
EndFunc
Return $aresult[0]
Func _winapi_getclientheight($hwnd)
Local $trect = _winapi_getclientrect($hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return DllStructGetData($trect, "Bottom") - DllStructGetData($tr
ect, "Top")
EndFunc
Func _winapi_getclientwidth($hwnd)
Local $trect = _winapi_getclientrect($hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return DllStructGetData($trect, "Right") - DllStructGetData($tre
ct, "Left")
EndFunc
Func _winapi_getclientrect($hwnd)
Local $trect = DllStructCreate($tagrect)
Local $aret = DllCall("user32.dll", "bool", "GetClientRect", "hw
nd", $hwnd, "struct*", $trect)
If @error OR NOT $aret[0] Then Return SetError(@error + 10, @ext
ended, 0)
Return $trect
EndFunc
ocess")
Func _winapi_getcurrentprocess()
Local $aresult = DllCall("kernel32.dll", "handle", "GetCurrentPr
EndFunc
Func _winapi_getcurrentprocessid()
Local $aresult = DllCall("kernel32.dll", "dword", "GetCurrentPro
cessId")
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
read")
Func _winapi_getcurrentthread()
Local $aresult = DllCall("kernel32.dll", "handle", "GetCurrentTh
EndFunc
eadId")
Func _winapi_getcurrentthreadid()
Local $aresult = DllCall("kernel32.dll", "dword", "GetCurrentThr
EndFunc
Func _winapi_getcursorinfo()
Local $tcursor = DllStructCreate($tagcursorinfo)
Local $icursor = DllStructGetSize($tcursor)
DllStructSetData($tcursor, "Size", $icursor)
Local $aret = DllCall("user32.dll", "bool", "GetCursorInfo", "st
ruct*", $tcursor)
If @error OR NOT $aret[0] Then Return SetError(@error + 10, @ext
ended, 0)
Local $acursor[5]
EndFunc
$acursor[0] = True
$acursor[1] = DllStructGetData($tcursor,
$acursor[2] = DllStructGetData($tcursor,
$acursor[3] = DllStructGetData($tcursor,
$acursor[4] = DllStructGetData($tcursor,
Return $acursor
"Flags") <> 0
"hCursor")
"X")
"Y")
Func _winapi_getdc($hwnd)
Local $aresult = DllCall("user32.dll", "handle", "GetDC", "hwnd"
, $hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
")
Func _winapi_getdesktopwindow()
Local $aresult = DllCall("user32.dll", "hwnd", "GetDesktopWindow
EndFunc
Func _winapi_getfocus()
Local $aresult = DllCall("user32.dll", "hwnd", "GetFocus")
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
dow")
Func _winapi_getforegroundwindow()
Local $aresult = DllCall("user32.dll", "hwnd", "GetForegroundWin
EndFunc
$itranscolor = -1
$itransgui = -1
Local $aresult = DllCall("user32.dll", "bool", "GetLayeredWindow
Attributes", "hwnd", $hwnd, "INT*", $itranscolor, "byte*", $itransgui, "dword*",
0)
If @error OR NOT $aresult[0] Then Return SetError(@error, @exten
ded, 0)
If NOT $bcolorref Then
$aresult[2] = Int(BinaryMid($aresult[2], 3, 1) & BinaryM
id($aresult[2], 2, 1) & BinaryMid($aresult[2], 1, 1))
EndIf
$itranscolor = $aresult[2]
$itransgui = $aresult[3]
Return $aresult[4]
EndFunc
Func _winapi_getmodulehandle($smodulename)
Local $smodulenametype = "wstr"
If $smodulename = "" Then
$smodulename = 0
$smodulenametype = "ptr"
EndIf
Local $aresult = DllCall("kernel32.dll", "handle", "GetModuleHan
dleW", $smodulenametype, $smodulename)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_getmousepos($btoclient = False, $hwnd = 0)
Local $imode = Opt("MouseCoordMode", 1)
Local $apos = MouseGetPos()
Opt("MouseCoordMode", $imode)
Local $tpoint = DllStructCreate($tagpoint)
DllStructSetData($tpoint, "X", $apos[0])
DllStructSetData($tpoint, "Y", $apos[1])
If $btoclient AND NOT _winapi_screentoclient($hwnd, $tpoint) The
n Return SetError(@error + 20, @extended, 0)
Return $tpoint
EndFunc
Func _winapi_getmouseposx($btoclient = False, $hwnd = 0)
Local $tpoint = _winapi_getmousepos($btoclient, $hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return DllStructGetData($tpoint, "X")
EndFunc
Func _winapi_getmouseposy($btoclient = False, $hwnd = 0)
Local $tpoint = _winapi_getmousepos($btoclient, $hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return DllStructGetData($tpoint, "Y")
EndFunc
Func _winapi_getobject($hobject, $isize, $pobject)
Local $aresult = DllCall("gdi32.dll", "int", "GetObjectW", "hand
le", $hobject, "int", $isize, "struct*", $pobject)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_getopenfilename($stitle = "", $sfilter = "All files (*.*)",
)
Else
$inulls += 1
$inulls = 0
EndIf
If $inulls = 2 Then ExitLoop
"|")
Next
DllStructSetData($tpath, "Path", Chr(0), $x - 1)
$afiles = StringSplit(DllStructGetData($tpath, "Path"),
EndFunc
Local $amask[3]
$amask[0] = True
$amask[1] = $aresult[2]
$amask[2] = $aresult[3]
Return $amask
ended, $afiles)
th"))
EndFunc
Func _winapi_getstockobject($iobject)
Local $aresult = DllCall("gdi32.dll", "handle", "GetStockObject"
, "int", $iobject)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
-1)
Func _winapi_getstdhandle($istdhandle)
If $istdhandle < 0 OR $istdhandle > 2 Then Return SetError(2, 0,
EndFunc
Func _winapi_getwindow($hwnd, $icmd)
Local $aresult = DllCall("user32.dll", "hwnd", "GetWindow", "hwn
d", $hwnd, "uint", $icmd)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_getwindowdc($hwnd)
Local $aresult = DllCall("user32.dll", "handle", "GetWindowDC",
"hwnd", $hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_getwindowheight($hwnd)
Local $trect = _winapi_getwindowrect($hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return DllStructGetData($trect, "Bottom") - DllStructGetData($tr
ect, "Top")
EndFunc
Func _winapi_getwindowlong($hwnd, $iindex)
Local $sfuncname = "GetWindowLongW"
If @AutoItX64 Then $sfuncname = "GetWindowLongPtrW"
Local $aresult = DllCall("user32.dll", "long_ptr", $sfuncname, "
hwnd", $hwnd, "int", $iindex)
If @error OR NOT $aresult[0] Then Return SetError(@error + 10, @
extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_getwindowplacement($hwnd)
Local $twindowplacement = DllStructCreate($tagwindowplacement)
DllStructSetData($twindowplacement, "length", DllStructGetSize($
twindowplacement))
Local $aret = DllCall("user32.dll", "bool", "GetWindowPlacement"
, "hwnd", $hwnd, "struct*", $twindowplacement)
If @error OR NOT $aret[0] Then Return SetError(@error + 10, @ext
ended, 0)
Return $twindowplacement
EndFunc
Func _winapi_getwindowrect($hwnd)
Local $trect = DllStructCreate($tagrect)
Local $aret = DllCall("user32.dll", "bool", "GetWindowRect", "hw
nd", $hwnd, "struct*", $trect)
If @error OR NOT $aret[0] Then Return SetError(@error + 10, @ext
ended, 0)
Return $trect
EndFunc
Func _winapi_getwindowrgn($hwnd, $hrgn)
Local $aresult = DllCall("user32.dll", "int", "GetWindowRgn", "h
wnd", $hwnd, "handle", $hrgn)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_getwindowtext($hwnd)
Local $aresult = DllCall("user32.dll", "int", "GetWindowTextW",
"hwnd", $hwnd, "wstr", "", "int", 4096)
If @error OR NOT $aresult[0] Then Return SetError(@error + 10, @
extended, "")
Return SetExtended($aresult[0], $aresult[2])
EndFunc
Func _winapi_getwindowthreadprocessid($hwnd, ByRef $ipid)
Local $aresult = DllCall("user32.dll", "dword", "GetWindowThread
ProcessId", "hwnd", $hwnd, "dword*", 0)
If @error Then Return SetError(@error, @extended, 0)
$ipid = $aresult[2]
Return $aresult[0]
EndFunc
Func _winapi_getwindowwidth($hwnd)
Local $trect = _winapi_getwindowrect($hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return DllStructGetData($trect, "Right") - DllStructGetData($tre
ct, "Left")
EndFunc
Func _winapi_getxyfrompoint(ByRef $tpoint, ByRef $ix, ByRef $iy)
$ix = DllStructGetData($tpoint, "X")
$iy = DllStructGetData($tpoint, "Y")
EndFunc
Func _winapi_globalmemorystatus()
Local $tmem = DllStructCreate($tagmemorystatusex)
DllStructSetData($tmem, 1, DllStructGetSize($tmem))
Local $aret = DllCall("kernel32.dll", "bool", "GlobalMemoryStatu
sEx", "struct*", $tmem)
If @error OR NOT $aret[0] Then Return SetError(@error + 10, @ext
ended, 0)
Local $amem[7]
$amem[0] = DllStructGetData($tmem, 2)
$amem[1] = DllStructGetData($tmem, 3)
$amem[2] = DllStructGetData($tmem, 4)
$amem[3] = DllStructGetData($tmem, 5)
$amem[4] = DllStructGetData($tmem, 6)
$amem[5] = DllStructGetData($tmem, 7)
$amem[6] = DllStructGetData($tmem, 8)
Return $amem
EndFunc
Func _winapi_guidfromstring($sguid)
Local $tguid = DllStructCreate($tagguid)
_winapi_guidfromstringex($sguid, $tguid)
If @error Then Return SetError(@error + 10, @extended, 0)
Return $tguid
EndFunc
Func _winapi_guidfromstringex($sguid, $tguid)
Local $aresult = DllCall("ole32.dll", "long", "CLSIDFromString",
"wstr", $sguid, "struct*", $tguid)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_hiword($ilong)
Return BitShift($ilong, 16)
EndFunc
Func _winapi_inprocess($hwnd, ByRef $hlastwnd)
If $hwnd = $hlastwnd Then Return True
For $ii = $__g_ainprocess_winapi[0][0] To 1 Step -1
If $hwnd = $__g_ainprocess_winapi[$ii][0] Then
If $__g_ainprocess_winapi[$ii][1] Then
$hlastwnd = $hwnd
Return True
Else
Return False
EndIf
EndIf
Next
Local $ipid
_winapi_getwindowthreadprocessid($hwnd, $ipid)
Local $icount = $__g_ainprocess_winapi[0][0] + 1
If $icount >= 64 Then $icount = 1
$__g_ainprocess_winapi[0][0] = $icount
$__g_ainprocess_winapi[$icount][0] = $hwnd
$__g_ainprocess_winapi[$icount][1] = ($ipid = @AutoItPID)
Return $__g_ainprocess_winapi[$icount][1]
EndFunc
Func _winapi_inttofloat($iint)
Local $tint = DllStructCreate("int")
Local $tfloat = DllStructCreate("float", DllStructGetPtr($tint))
DllStructSetData($tint, 1, $iint)
Return DllStructGetData($tfloat, 1)
EndFunc
Func _winapi_isclassname($hwnd, $sclassname)
Local $sseparator = Opt("GUIDataSeparatorChar")
Local $aclassname = StringSplit($sclassname, $sseparator)
If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
Local $sclasscheck = _winapi_getclassname($hwnd)
For $x = 1 To UBound($aclassname) - 1
If StringUpper(StringMid($sclasscheck, 1, StringLen($acl
assname[$x]))) = StringUpper($aclassname[$x]) Then Return True
Next
Return False
EndFunc
Func _winapi_iswindow($hwnd)
Local $aresult = DllCall("user32.dll", "bool", "IsWindow", "hwnd
", $hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_iswindowvisible($hwnd)
Local $aresult = DllCall("user32.dll", "bool", "IsWindowVisible"
, "hwnd", $hwnd)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_invalidaterect($hwnd, $trect = 0, $berase = True)
extended, "")
EndFunc
Func _winapi_localfree($hmemory)
Local $aresult = DllCall("kernel32.dll", "handle", "LocalFree",
"handle", $hmemory)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_loword($ilong)
Return BitAND($ilong, 65535)
EndFunc
Func _winapi_makelangid($ilngidprimary, $ilngidsub)
Return BitOR(BitShift($ilngidsub, -10), $ilngidprimary)
EndFunc
Func _winapi_makelcid($ilngid, $isortid)
Return BitOR(BitShift($isortid, -16), $ilngid)
EndFunc
Func _winapi_makelong($ilo, $ihi)
Return BitOR(BitShift($ihi, -16), BitAND($ilo, 65535))
EndFunc
Func _winapi_makeqword($ilodword, $ihidword)
Local $tint64 = DllStructCreate("uint64")
Local $tdwords = DllStructCreate("dword;dword", DllStructGetPtr(
$tint64))
DllStructSetData($tdwords, 1, $ilodword)
DllStructSetData($tdwords, 2, $ihidword)
Return DllStructGetData($tint64, 1)
EndFunc
Func _winapi_messagebeep($itype = 1)
Local $isound
Switch $itype
Case 1
$isound = 0
Case 2
$isound = 16
Case 3
$isound = 32
Case 4
$isound = 48
Case 5
$isound = 64
Case Else
$isound = -1
EndSwitch
Local $aresult = DllCall("user32.dll", "bool", "MessageBeep", "u
int", $isound)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_msgbox($iflags, $stitle, $stext)
BlockInput(0)
EndFunc
")
EndFunc
)
"];"
If $iextracount Then
Local $tagstruct = ""
For $path In $aextrapaths
$tagstruct &= "wchar[" & StringLen($path) + 1 &
Next
$tpaths = DllStructCreate($tagstruct)
$tpathptrs = DllStructCreate("ptr[" & $iextracount + 1 &
"]")
For $i = 1 To $iextracount
DllStructSetData($tpaths, $i, $aextrapaths[$i -
1])
$tpaths, $i), $i)
)
DllStructSetData($tpathptrs, 1, DllStructGetPtr(
Next
DllStructSetData($tpathptrs, 1, Ptr(0), $iextracount + 1
EndIf
Local $aresult = DllCall("shlwapi.dll", "bool", "PathFindOnPathW
", "wstr", $sfilepath, "struct*", $tpathptrs)
If @error OR NOT $aresult[0] Then Return SetError(@error + 10, @
extended, $sfilepath)
Return $aresult[1]
EndFunc
Func _winapi_pointfromrect(ByRef $trect, $bcenter = True)
Local $ix1 = DllStructGetData($trect, "Left")
Local $iy1 = DllStructGetData($trect, "Top")
Local $ix2 = DllStructGetData($trect, "Right")
Local $iy2 = DllStructGetData($trect, "Bottom")
If $bcenter Then
$ix1 = $ix1 + (($ix2 - $ix1) / 2)
$iy1 = $iy1 + (($iy2 - $iy1) / 2)
EndIf
Local $tpoint = DllStructCreate($tagpoint)
DllStructSetData($tpoint, "X", $ix1)
DllStructSetData($tpoint, "Y", $iy1)
Return $tpoint
EndFunc
Func _winapi_postmessage($hwnd, $imsg, $wparam, $lparam)
Local $aresult = DllCall("user32.dll", "bool", "PostMessage", "h
wnd", $hwnd, "uint", $imsg, "wparam", $wparam, "lparam", $lparam)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_primarylangid($ilngid)
Return BitAND($ilngid, 1023)
EndFunc
Func _winapi_ptinrect(ByRef $trect, ByRef $tpoint)
Local $aresult = DllCall("user32.dll", "bool", "PtInRect", "stru
ct*", $trect, "struct", $tpoint)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_readfile($hfile, $pbuffer, $itoread, ByRef $iread, $toverla
pped = 0)
EndFunc
Return $aresult[0]
olors)
Local $ielementnum
If NOT $biscarray AND NOT $bisearray Then
$ielementnum = 1
ElseIf $biscarray OR $bisearray Then
If NOT $biscarray OR NOT $bisearray Then Return SetError
& "]")
& "]")
ts[$x], $x + 1)
$x], $x + 1)
$ielementnum = UBound($velements)
EndIf
Local $telements = DllStructCreate("int Element[" & $ielementnum
Local $tcolors = DllStructCreate("INT NewColor[" & $ielementnum
If NOT $bisearray Then
DllStructSetData($telements, "Element", $velements, 1)
Else
For $x = 0 To $ielementnum - 1
DllStructSetData($telements, "Element", $velemen
Next
EndIf
If NOT $biscarray Then
DllStructSetData($tcolors, "NewColor", $vcolors, 1)
Else
For $x = 0 To $ielementnum - 1
DllStructSetData($tcolors, "NewColor", $vcolors[
Next
EndIf
Local $aresult = DllCall("user32.dll", "bool", "SetSysColors", "
int", $ielementnum, "struct*", $telements, "struct*", $tcolors)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_settextcolor($hdc, $icolor)
Local $aresult = DllCall("gdi32.dll", "INT", "SetTextColor", "ha
ndle", $hdc, "INT", $icolor)
If @error Then Return SetError(@error, @extended, -1)
Return $aresult[0]
EndFunc
Func _winapi_setwindowlong($hwnd, $iindex, $ivalue)
_winapi_setlasterror(0)
Local $sfuncname = "SetWindowLongW"
If @AutoItX64 Then $sfuncname = "SetWindowLongPtrW"
Local $aresult = DllCall("user32.dll", "long_ptr", $sfuncname, "
hwnd", $hwnd, "int", $iindex, "long_ptr", $ivalue)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func _winapi_setwindowplacement($hwnd, $twindowplacement)
Local $aresult = DllCall("user32.dll", "bool", "SetWindowPlaceme
nt", "hwnd", $hwnd, "struct*", $twindowplacement)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
EndFunc
Func _winapi_updatewindow($hwnd)
Local $aresult = DllCall("user32.dll", "bool", "UpdateWindow", "
hwnd", $hwnd)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_waitforinputidle($hprocess, $itimeout = -1)
Local $aresult = DllCall("user32.dll", "dword", "WaitForInputIdl
e", "handle", $hprocess, "dword", $itimeout)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0]
EndFunc
Func _winapi_waitformultipleobjects($icount, $pahandles, $bwaitall = Fal
se, $itimeout = -1)
Local $aresult = DllCall("kernel32.dll", "INT", "WaitForMultiple
Objects", "dword", $icount, "struct*", $pahandles, "bool", $bwaitall, "dword", $
itimeout)
If @error Then Return SetError(@error, @extended, -1)
Return $aresult[0]
EndFunc
Func _winapi_waitforsingleobject($hhandle, $itimeout = -1)
Local $aresult = DllCall("kernel32.dll", "INT", "WaitForSingleOb
ject", "handle", $hhandle, "dword", $itimeout)
If @error Then Return SetError(@error, @extended, -1)
Return $aresult[0]
EndFunc
= True)
If $iusedindex = -1 Then
For $iindex = 0 To $_udf_globalid_max_win - 1
If $__g_audf_globalids_used[$iindex][0] = 0 Then
$__g_audf_globalids_used[$iindex][0] = $
hwnd
$__g_audf_globalids_used[$iindex][1] = $
_udf_startid
Next
EndIf
$ballused = False
$iusedindex = $iindex
ExitLoop
EndIf
If $iusedindex = -1 AND $ballused Then Return SetError(16, 0, 0)
If $__g_audf_globalids_used[$iusedindex][1] = $_udf_startid + $_
udf_globalid_max_ids Then
For $iidindex = $_udf_globalids_offset To UBound($__g_au
df_globalids_used, $ubound_columns) - 1
If $__g_audf_globalids_used[$iusedindex][$iidind
ex] = 0 Then
$nctrlid = ($iidindex - $_udf_globalids_
offset) + 10000
$__g_audf_globalids_used[$iusedindex][$i
idindex] = $nctrlid
Return $nctrlid
EndIf
Next
Return SetError(-1, $_udf_globalid_max_ids, 0)
EndIf
$nctrlid = $__g_audf_globalids_used[$iusedindex][1]
$__g_audf_globalids_used[$iusedindex][1] += 1
$__g_audf_globalids_used[$iusedindex][($nctrlid - 10000) + $_udf
_globalids_offset] = $nctrlid
Return $nctrlid
EndFunc
Func __udf_freeglobalid($hwnd, $iglobalid)
If $iglobalid - $_udf_startid < 0 OR $iglobalid - $_udf_startid
> $_udf_globalid_max_ids Then Return SetError(-1, 0, False)
For $iindex = 0 To $_udf_globalid_max_win - 1
If $__g_audf_globalids_used[$iindex][0] = $hwnd Then
For $x = $_udf_globalids_offset To UBound($__g_a
udf_globalids_used, $ubound_columns) - 1
If $__g_audf_globalids_used[$iindex][$x]
= $iglobalid Then
$__g_audf_globalids_used[$iindex
][$x] = 0
Return True
EndIf
Next
Return SetError(-3, 0, False)
EndIf
Next
Return SetError(-2, 0, False)
EndFunc
Global
Global
Global
Global
$__g_hsblastwnd
Const $__statusbarconstant_classname = "msctls_statusbar32"
Const $__statusbarconstant_wm_size = 5
Const $__statusbarconstant_clr_default = -16777216
$x], $x)
EndFunc
Next
EndIf
Return $hwndsbar
dx
EndFunc
EndIf
_winapi_setparent($hcontrol, $hwnd)
_winapi_movewindow($hcontrol, $iconx, $icony, $iconw, $iconh)
Func _guictrlstatusbar_getborders($hwnd)
+ 1
")
$ibuffer *= 2
$tbuffer = DllStructCreate("char Text[" & $ibuffer & "]"
EndIf
If _winapi_inprocess($hwnd, $__g_hsblastwnd) Then
_sendmessage($hwnd, $sb_gettextw, $ipart, $tbuffer, 0, "
wparam", "struct*")
Else
EndFunc
Local $tmemmap
Local $pmemory = _meminit($hwnd, $ibuffer, $tmemmap)
If $bunicode Then
_sendmessage($hwnd, $sb_gettextw, $ipart, $pmemo
Else
EndIf
_memread($tmemmap, $pmemory, $tbuffer, $ibuffer)
_memfree($tmemmap)
EndIf
Return DllStructGetData($tbuffer, "Text")
rt))
rt))
Func _guictrlstatusbar_getunicodeformat($hwnd)
Return _sendmessage($hwnd, $sb_getunicodeformat) <> 0
EndFunc
Func _guictrlstatusbar_getwidth($hwnd, $ipart)
Local $trect = _guictrlstatusbar_getrectex($hwnd, $ipart)
Return DllStructGetData($trect, "Right") - DllStructGetData($tre
ct, "Left") - (_guictrlstatusbar_getbordershorz($hwnd) * 2)
EndFunc
Func _guictrlstatusbar_issimple($hwnd)
Return _sendmessage($hwnd, $sb_issimple) <> 0
EndFunc
Func _guictrlstatusbar_resize($hwnd)
_sendmessage($hwnd, $__statusbarconstant_wm_size)
EndFunc
Func _guictrlstatusbar_setbkcolor($hwnd, $icolor)
$icolor = _sendmessage($hwnd, $sb_setbkcolor, 0, $icolor)
If $icolor = $__statusbarconstant_clr_default Then Return "0x" &
Hex($__statusbarconstant_clr_default)
Return $icolor
EndFunc
"")
+ 1)
x)
Else
Next
DllStructSetData($tparts, 1, -1, $iparts)
$tparts = DllStructCreate("int")
DllStructSetData($tparts, $iparts, -1)
EndIf
If _winapi_inprocess($hwnd, $__g_hsblastwnd) Then
_sendmessage($hwnd, $sb_setparts, $iparts, $tparts, 0, "
wparam", "struct*")
Else
Local $isize = DllStructGetSize($tparts)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $isize, $tmemmap)
_memwrite($tmemmap, $tparts)
_sendmessage($hwnd, $sb_setparts, $iparts, $pmemory, 0,
"wparam", "ptr")
_memfree($tmemmap)
EndIf
_guictrlstatusbar_resize($hwnd)
Return True
EndFunc
Func _guictrlstatusbar_setsimple($hwnd, $bsimple = True)
_sendmessage($hwnd, $sb_simple, $bsimple)
EndFunc
0)
_memwrite($tmemmap, $ttext)
If $bunicode Then
$iret = _sendmessage($hwnd, $sb_settextw, BitOR(
$ipart, $iuflag), $pmemory, 0, "wparam", "ptr")
Else
$iret = _sendmessage($hwnd, $sb_settext, BitOR($
ipart, $iuflag), $pmemory, 0, "wparam", "ptr")
EndIf
_memfree($tmemmap)
EndIf
Return $iret <> 0
EndFunc
]")
")
$ibuffer *= 2
$ttext = DllStructCreate("char TipText[" & $ibuffer & "]
EndIf
DllStructSetData($ttext, "TipText", $stext)
If _winapi_inprocess($hwnd, $__g_hsblastwnd) Then
_sendmessage($hwnd, $sb_settiptextw, $ipart, $ttext, 0,
"wparam", "struct*")
Else
Local $tmemmap
Local $pmemory = _meminit($hwnd, $ibuffer, $tmemmap)
_memwrite($tmemmap, $ttext, $pmemory, $ibuffer)
If $bunicode Then
_sendmessage($hwnd, $sb_settiptextw, $ipart, $pm
emory, 0, "wparam", "ptr")
Else
_sendmessage($hwnd, $sb_settiptexta, $ipart, $pm
emory, 0, "wparam", "ptr")
EndIf
_memfree($tmemmap)
EndIf
EndFunc
Func _guictrlstatusbar_setunicodeformat($hwnd, $bunicode = True)
Return _sendmessage($hwnd, $sb_setunicodeformat, $bunicode)
EndFunc
Func _guictrlstatusbar_showhide($hwnd, $istate)
If $istate <> @SW_HIDE AND $istate <> @SW_SHOW Then Return SetEr
ror(1, 1, False)
Return _winapi_showwindow($hwnd, $istate)
EndFunc
Global Enum $arrayfill_force_default, $arrayfill_force_singleitem, $arra
yfill_force_int, $arrayfill_force_number, $arrayfill_force_ptr, $arrayfill_force
_hwnd, $arrayfill_force_string
Global Enum $arrayunique_nocount, $arrayunique_count
Global Enum $arrayunique_auto, $arrayunique_force32, $arrayunique_force6
4, $arrayunique_match, $arrayunique_distinct
Global $g_oarrayuniquecomerrorhandler = 0
Func _arrayadd(ByRef $aarray, $vvalue, $istart = 0, $sdelim_item = "|",
$sdelim_row = @CRLF, $iforce = $arrayfill_force_default)
If $istart = Default Then $istart = 0
If $sdelim_item = Default Then $sdelim_item = "|"
If $sdelim_row = Default Then $sdelim_row = @CRLF
If $iforce = Default Then $iforce = $arrayfill_force_default
If NOT IsArray($aarray) Then Return SetError(1, 0, -1)
Local $idim_1 = UBound($aarray, $ubound_rows)
Local $hdatatype = 0
Switch $iforce
Case $arrayfill_force_int
$hdatatype = Int
Case $arrayfill_force_number
$hdatatype = Number
Case $arrayfill_force_ptr
$hdatatype = Ptr
Case $arrayfill_force_hwnd
$hdatatype = HWnd
Case $arrayfill_force_string
$hdatatype = String
EndSwitch
Switch UBound($aarray, $ubound_dimensions)
Case 1
If $iforce = $arrayfill_force_singleitem Then
ReDim $aarray[$idim_1 + 1]
$aarray[$idim_1] = $vvalue
Return $idim_1
EndIf
If IsArray($vvalue) Then
If UBound($vvalue, $ubound_dimensions) <
> 1 Then Return SetError(5, 0, -1)
$hdatatype = 0
Else
Local $atmp = StringSplit($vvalue, $sdel
im_item, $str_nocount + $str_entiresplit)
If UBound($atmp, $ubound_rows) = 1 Then
$atmp[0] = $vvalue
EndIf
$vvalue = $atmp
EndIf
Local $iadd = UBound($vvalue, $ubound_rows)
ReDim $aarray[$idim_1 + $iadd]
For $i = 0 To $iadd - 1
If IsFunc($hdatatype) Then
$aarray[$idim_1 + $i] = $hdataty
pe($vvalue[$i])
Else
$aarray[$idim_1 + $i] = $vvalue[
$i]
EndIf
Next
Return $idim_1 + $iadd - 1
Case 2
Local $idim_2 = UBound($aarray, $ubound_columns)
If $istart < 0 OR $istart > $idim_2 - 1 Then Ret
urn SetError(4, 0, -1)
Local $ivaldim_1, $ivaldim_2 = 0, $icolcount
If IsArray($vvalue) Then
umns)
Else
$hdatatype = 0
= 0, $icolumn = 0)
If $istart = Default Then $istart = 0
If $iend = Default Then $iend = 0
If $icolumn = Default Then $icolumn = 0
If NOT IsArray($aarray) Then Return SetError(1, 0, -1)
Local $idim_1 = UBound($aarray, $ubound_rows)
If $idim_1 = 0 Then Return SetError(6, 0, -1)
If $iend < 1 OR $iend > $idim_1 - 1 Then $iend = $idim_1 - 1
If $istart < 0 Then $istart = 0
If $istart > $iend Then Return SetError(4, 0, -1)
Local $imid = Int(($iend + $istart) / 2)
Switch UBound($aarray, $ubound_dimensions)
Case 1
If $aarray[$istart] > $vvalue OR $aarray[$iend]
< $vvalue Then Return SetError(2, 0, -1)
While $istart <= $imid AND $vvalue <> $aarray[$i
mid]
If $vvalue < $aarray[$imid] Then
$iend = $imid - 1
Else
$istart = $imid + 1
EndIf
$imid = Int(($iend + $istart) / 2)
WEnd
If $istart > $iend Then Return SetError(3, 0, -1
)
Case 2
Local $idim_2 = UBound($aarray, $ubound_columns)
- 1
If $icolumn < 0 OR $icolumn > $idim_2 Then Retur
n SetError(7, 0, -1)
If $aarray[$istart][$icolumn] > $vvalue OR $aarr
ay[$iend][$icolumn] < $vvalue Then Return SetError(2, 0, -1)
While $istart <= $imid AND $vvalue <> $aarray[$i
mid][$icolumn]
If $vvalue < $aarray[$imid][$icolumn] Th
en
$iend = $imid - 1
Else
$istart = $imid + 1
EndIf
$imid = Int(($iend + $istart) / 2)
WEnd
If $istart > $iend Then Return SetError(3, 0, -1
)
Case Else
Return SetError(5, 0, -1)
EndSwitch
Return $imid
EndFunc
Func _arraycoldelete(ByRef $aarray, $icolumn, $bconvert = False)
If $bconvert = Default Then $bconvert = False
If NOT IsArray($aarray) Then Return SetError(1, 0, -1)
Local $idim_1 = UBound($aarray, $ubound_rows)
If UBound($aarray, $ubound_dimensions) <> 2 Then Return SetError
(2, 0, -1)
Local $idim_2 = UBound($aarray, $ubound_columns)
Switch $idim_2
Case 2
rror(3, 0, -1)
If $bconvert Then
Local $atemparray[$idim_1]
For $i = 0 To $idim_1 - 1
$atemparray[$i] = $aarray[$i][(N
OT $icolumn)]
Else
+ 1]
Next
$aarray = $atemparray
ContinueCase
EndIf
Case Else
If $icolumn < 0 OR $icolumn > $idim_2 - 1 Then R
For $i = 0 To $idim_1 - 1
For $j = $icolumn To $idim_2 - 2
$aarray[$i][$j] = $aarray[$i][$j
Next
Next
ReDim $aarray[$idim_1][$idim_2 - 1]
EndFunc
EndSwitch
Return UBound($aarray, $ubound_columns)
$istart][$idim_2_tgt]
index Then
$aarray[$icopyto_index]
= $aarray[$ireadfrom_index]
Case 2
- 1
64177) Then
EndIf
$icopyto_index += 1
EndIf
Next
ReDim $aarray[$idim_1 - $vrange[0] + 1]
Local $idim_2 = UBound($aarray, $ubound_columns)
For $i = 1 To $vrange[0]
$aarray[$vrange[$i]][0] = ChrW(64177)
Next
For $ireadfrom_index = 0 To $idim_1
If $aarray[$ireadfrom_index][0] == ChrW(
Else
index Then
_index][$j] = $aarray[$ireadfrom_index][$j]
ContinueLoop
If $ireadfrom_index <> $icopyto_
For $j = 0 To $idim_2
$aarray[$icopyto
Next
EndIf
$icopyto_index += 1
EndIf
Next
ReDim $aarray[$idim_1 - $vrange[0] + 1][$idim_2
+ 1]
EndFunc
Case Else
Return SetError(2, 0, False)
EndSwitch
Return UBound($aarray, $ubound_rows)
"
Else
EndIf
$iret = 2
_end = $icolcount - 1
$isubitem_end = Number($avrangesplit[2])
EndIf
If $isubitem_start > $isubitem_end Then
$vtmp = $isubitem_start
$isubitem_start = $isubitem_end
$isubitem_end = $vtmp
EndIf
If $isubitem_start < 0 Then $isubitem_start = 0
If $isubitem_end > $icolcount - 1 Then $isubitem
ocount)
tLoop
iindex]
EndIf
If $itranspose Then
If $stipdata Then $stipdata &= " - "
$stipdata &= "Transposed"
EndIf
Local $asheader = StringSplit($sheader, $scurr_separator, $str_n
If UBound($asheader) = 0 Then Local $asheader[1] = [""]
$sheader = "Row"
Local $iindex = $isubitem_start
If $itranspose Then
For $j = $iitem_start To $iitem_end
$sheader &= $sad_separator & "Col " & $j
Next
Else
If $asheader[0] Then
For $iindex = $isubitem_start To $isubitem_end
If $iindex >= UBound($asheader) Then Exi
$sheader &= $sad_separator & $asheader[$
Next
EndIf
For $j = $iindex To $isubitem_end
$sheader &= $sad_separator & "Col " & $j
Next
EndIf
If $inorow Then $sheader = StringTrimLeft($sheader, 4)
If $iverbose AND ($iitem_end - $iitem_start + 1) * ($isubitem_en
d - $isubitem_start + 1) > 10000 Then
SplashTextOn("ArrayDisplay", "Preparing display" & @CRLF
& @CRLF & "Please be patient", 300, 100)
EndIf
Local $ibuffer = 4094
If $itranspose Then
$vtmp = $iitem_start
$iitem_start = $isubitem_start
$isubitem_start = $vtmp
$vtmp = $iitem_end
$iitem_end = $isubitem_end
$isubitem_end = $vtmp
EndIf
Local $avarraytext[$iitem_end - $iitem_start + 1]
For $i = $iitem_start To $iitem_end
If NOT $inorow Then $avarraytext[$i - $iitem_start] = "[
" & $i & "]"
For $j = $isubitem_start To $isubitem_end
If $idimension = 1 Then
If $itranspose Then
Switch VarGetType($aarray[$j])
Case "Array"
$vtmp = "{Array}
"
Case Else
$vtmp = $aarray[
$j]
EndSwitch
Else
Switch VarGetType($aarray[$i])
Case "Array"
$vtmp = "{Array}
"
Case Else
$vtmp = $aarray[
$i]
Else
])
EndIf
If $itranspose Then
Switch VarGetType($aarray[$j][$i
Case "Array"
$vtmp = "{Array}
"
Case Else
$vtmp = $aarray[
$j][$i]
Else
])
Switch VarGetType($aarray[$i][$j
Case Else
$vtmp = $aarray[
$i][$j]
EndIf
r & $vtmp
EndSwitch
Case "Array"
$vtmp = "{Array}
"
ngLeft($vtmp, $ibuffer)
EndSwitch
EndSwitch
EndIf
If StringLen($vtmp) > $ibuffer Then $vtmp = Stri
$avarraytext[$i - $iitem_start] &= $sad_separato
Next
If $inorow Then $avarraytext[$i - $iitem_start] = String
TrimLeft($avarraytext[$i - $iitem_start], 1)
Next
Local Const $_arrayconstant_gui_dockbottom = 64
Local Const $_arrayconstant_gui_dockborders = 102
Local Const $_arrayconstant_gui_dockheight = 512
Local Const $_arrayconstant_gui_dockleft = 2
Local Const $_arrayconstant_gui_dockright = 4
Local Const $_arrayconstant_gui_dockhcenter = 8
Local Const $_arrayconstant_gui_event_close = -3
Local Const $_arrayconstant_gui_focus = 256
Local Const $_arrayconstant_gui_bkcolor_lv_alternate = -33554432
Local Const $_arrayconstant_ss_center = 1
Local Const $_arrayconstant_ss_centerimage = 512
Local Const $_arrayconstant_lvm_getitemcount = (4096 + 4)
Local Const $_arrayconstant_lvm_getitemrect = (4096 + 14)
Local Const $_arrayconstant_lvm_getcolumnwidth = (4096 + 29)
Local Const $_arrayconstant_lvm_setcolumnwidth = (4096 + 30)
Local Const $_arrayconstant_lvm_getitemstate = (4096 + 44)
Local Const $_arrayconstant_lvm_getselectedcount = (4096 + 50)
Local Const $_arrayconstant_lvm_setextendedlistviewstyle = (4096
+ 54)
Local Const $_arrayconstant_lvs_ex_gridlines = 1
Local Const $_arrayconstant_lvis_selected = 2
Local Const $_arrayconstant_lvs_showselalways = 8
GUICtrlSetResizing($idcopy_data, $_arrayconstant_gui_dockright +
$_arrayconstant_gui_dockbottom + $_arrayconstant_gui_dockheight)
GUICtrlSetResizing($iddata_label, $_arrayconstant_gui_dockleft +
$_arrayconstant_gui_dockbottom + $_arrayconstant_gui_dockheight)
GUICtrlSetResizing($iduser_func, $_arrayconstant_gui_dockhcenter
+ $_arrayconstant_gui_dockbottom + $_arrayconstant_gui_dockheight)
GUICtrlSetResizing($idexit_script, $_arrayconstant_gui_dockright
+ $_arrayconstant_gui_dockbottom + $_arrayconstant_gui_dockheight)
GUICtrlSendMsg($idlistview, $_arrayconstant_wm_setredraw, 0, 0)
Local $iditem
For $i = 0 To UBound($avarraytext) - 1
$iditem = GUICtrlCreateListViewItem($avarraytext[$i], $i
dlistview)
If $ialt_color Then
GUICtrlSetBkColor($iditem, $ialt_color)
EndIf
Next
If $icolalign Then
Local Const $_arrayconstant_lvcf_fmt = 1
Local Const $_arrayconstant_lvm_setcolumnw = (4096 + 96)
Local $tcolumn = DllStructCreate("uint Mask;int Fmt;int
CX;ptr Text;int TextMax;int SubItem;int Image;int Order;int cxMin;int cxDefault;
int cxIdeal")
DllStructSetData($tcolumn, "Mask", $_arrayconstant_lvcf_
fmt)
DllStructSetData($tcolumn, "Fmt", $icolalign / 2)
Local $pcolumn = DllStructGetPtr($tcolumn)
For $i = 1 To $isubitem_end - $isubitem_start + 1
GUICtrlSendMsg($idlistview, $_arrayconstant_lvm_
setcolumnw, $i, $pcolumn)
Next
EndIf
GUICtrlSendMsg($idlistview, $_arrayconstant_wm_setredraw, 1, 0)
Local $iborder = 45
If UBound($avarraytext) > 20 Then
$iborder += 20
EndIf
Local $iwidth = $iborder, $icolwidth = 0, $aicolwidth[$isubitem_
end - $isubitem_start + 2], $imin_colwidth = 55
For $i = 0 To $isubitem_end - $isubitem_start + 1
GUICtrlSendMsg($idlistview, $_arrayconstant_lvm_setcolum
nwidth, $i, $_arrayconstant_lvscw_autosize)
$icolwidth = GUICtrlSendMsg($idlistview, $_arrayconstant
_lvm_getcolumnwidth, $i, 0)
If $icolwidth < $imin_colwidth Then
GUICtrlSendMsg($idlistview, $_arrayconstant_lvm_
setcolumnwidth, $i, $imin_colwidth)
$icolwidth = $imin_colwidth
EndIf
$iwidth += $icolwidth
$aicolwidth[$i] = $icolwidth
Next
If $inorow Then $iwidth -= 55
If $iwidth > @DesktopWidth - 100 Then
$iwidth = $iborder
For $i = 0 To $isubitem_end - $isubitem_start + 1
If $aicolwidth[$i] > $imax_colwidth Then
GUICtrlSendMsg($idlistview, $_arrayconst
ant_lvm_setcolumnwidth, $i, $imax_colwidth)
$iwidth += $imax_colwidth
Else
EndIf
$iwidth += $aicolwidth[$i]
Next
EndIf
If $iwidth > @DesktopWidth - 100 Then
$iwidth = @DesktopWidth - 100
ElseIf $iwidth < $iminsize Then
$iwidth = $iminsize
EndIf
Local $trect = DllStructCreate("struct; long Left;long Top;long
Right;long Bottom; endstruct")
DllCall("user32.dll", "struct*", "SendMessageW", "hwnd", GUICtrl
GetHandle($idlistview), "uint", $_arrayconstant_lvm_getitemrect, "wparam", 0, "s
truct*", $trect)
Local $aiwin_pos = WinGetPos($hgui)
Local $ailv_pos = ControlGetPos($hgui, "", $idlistview)
$iheight = ((UBound($avarraytext) + 2) * (DllStructGetData($trec
t, "Bottom") - DllStructGetData($trect, "Top"))) + $aiwin_pos[3] - $ailv_pos[3]
If $iheight > @DesktopHeight - 100 Then
$iheight = @DesktopHeight - 100
ElseIf $iheight < $iminsize Then
$iheight = $iminsize
EndIf
If $iverbose Then SplashOff()
GUISetState(@SW_HIDE, $hgui)
WinMove($hgui, "", (@DesktopWidth - $iwidth) / 2, (@DesktopHeigh
t - $iheight) / 2, $iwidth, $iheight)
GUISetState(@SW_SHOW, $hgui)
Local $ioneventmode = Opt("GUIOnEventMode", 0), $imsg
While 1
$imsg = GUIGetMsg()
Switch $imsg
Case $_arrayconstant_gui_event_close
ExitLoop
Case $idcopy_id, $idcopy_data
Local $isel_count = GUICtrlSendMsg($idli
stview, $_arrayconstant_lvm_getselectedcount, 0, 0)
If $iverbose AND (NOT $isel_count) AND (
$iitem_end - $iitem_start) * ($isubitem_end - $isubitem_start) > 10000 Then
SplashTextOn("ArrayDisplay", "Co
pying data" & @CRLF & @CRLF & "Please be patient", 300, 100)
EndIf
Local $sclip = "", $sitem, $asplit
For $i = 0 To $iitem_end - $iitem_start
If $isel_count AND NOT (GUICtrlS
endMsg($idlistview, $_arrayconstant_lvm_getitemstate, $i, $_arrayconstant_lvis_s
elected)) Then
ContinueLoop
EndIf
$sitem = $avarraytext[$i]
If $imsg = $idcopy_data Then
$sitem = StringRegExpRep
lace($sitem, "^\[\d+\].(.*)$", "$1")
EndIf
If $icw_colwidth Then
$asplit = StringSplit($s
item, $sad_separator)
$sitem = ""
For $j = 1 To $asplit[0]
-1)
rror(3, 0, -1)
w]
Case 2
- 1
n SetError(5, 0, -1)
Then Return SetError(5, 0, -1)
6, 0, -1)
+ 1]
Next
Return $aretarray
Local $idim_2 = UBound($aarray, $ubound_columns)
If $iend_col = -1 Then $iend_col = $idim_2
If $istart_col = -1 Then $istart_col = 0
If $istart_col < -1 OR $iend_col < -1 Then Retur
If $istart_col > $idim_2 OR $iend_col > $idim_2
If $istart_col > $iend_col Then Return SetError(
If $istart_col = $iend_col Then
Local $aretarray[$iend_row - $istart_row
Else
Do
ber & ";"
$inumber += 1
$vrange &= $inum
_2[2]
EndSwitch
EndIf
Next
$vrange = StringSplit(StringTrimRight($vrange, 1), ";")
EndIf
If $vrange[1] < 0 OR $vrange[$vrange[0]] > $idim_1 Then Return S
etError(5, 0, -1)
For $i = 2 To $vrange[0]
If $vrange[$i] < $vrange[$i - 1] Then Return SetError(3,
0, -1)
Next
Local $icopyto_index = $idim_1 + $vrange[0]
Local $iinsertpoint_index = $vrange[0]
Local $iinsert_index = $vrange[$iinsertpoint_index]
Switch UBound($aarray, $ubound_dimensions)
Case 1
If $iforce = $arrayfill_force_singleitem Then
ReDim $aarray[$idim_1 + $vrange[0] + 1]
For $ireadfromindex = $idim_1 To 0 Step
-1
$aarray[$icopyto_index] = $aarra
y[$ireadfromindex]
$icopyto_index -= 1
$iinsert_index = $vrange[$iinser
tpoint_index]
While $ireadfromindex = $iinsert
_index
$aarray[$icopyto_index]
= $vvalue
$icopyto_index -= 1
$iinsertpoint_index -= 1
If $iinsertpoint_index <
1 Then ExitLoop 2
$iinsert_index = $vrange
[$iinsertpoint_index]
WEnd
Next
Return $idim_1 + $vrange[0] + 1
EndIf
ReDim $aarray[$idim_1 + $vrange[0] + 1]
If IsArray($vvalue) Then
If UBound($vvalue, $ubound_dimensions) <
> 1 Then Return SetError(5, 0, -1)
$hdatatype = 0
Else
Local $atmp = StringSplit($vvalue, $sdel
im_item, $str_nocount + $str_entiresplit)
If UBound($atmp, $ubound_rows) = 1 Then
$atmp[0] = $vvalue
$hdatatype = 0
EndIf
$vvalue = $atmp
EndIf
For $ireadfromindex = $idim_1 To 0 Step -1
$aarray[$icopyto_index] = $aarray[$iread
fromindex]
$icopyto_index -= 1
$iinsert_index = $vrange[$iinsertpoint_i
ndex]
If IsFunc($hdatatype) Th
en
_index] = $hdatatype($vvalue[$iinsertpoint_index - 1])
_index] = $vvalue[$iinsertpoint_index - 1]
Else
= ""
Else
$aarray[$icopyto
EndIf
$aarray[$icopyto_index]
EndIf
$icopyto_index -= 1
$iinsertpoint_index -= 1
If $iinsertpoint_index = 0 Then
ExitLoop 2
$iinsert_index = $vrange[$iinser
tpoint_index]
Case 2
urn SetError(6, 0, -1)
$aarray[$icopyto
Next
WEnd
EndFunc
EndIf
Return $aarray[$iresult][$isubitem]
EndFunc
Func _arraypop(ByRef $aarray)
If (NOT IsArray($aarray)) Then Return SetError(1, 0, "")
If UBound($aarray, $ubound_dimensions) <> 1 Then Return SetError
(2, 0, "")
Local $iubound = UBound($aarray) - 1
If $iubound = -1 Then Return SetError(3, 0, "")
Local $slastval = $aarray[$iubound]
If $iubound > -1 Then
ReDim $aarray[$iubound]
EndIf
Return $slastval
EndFunc
Func _arraypush(ByRef $aarray, $vvalue, $idirection = 0)
If $idirection = Default Then $idirection = 0
If (NOT IsArray($aarray)) Then Return SetError(1, 0, 0)
If UBound($aarray, $ubound_dimensions) <> 1 Then Return SetError
(3, 0, 0)
Local $iubound = UBound($aarray) - 1
If IsArray($vvalue) Then
Local $iubounds = UBound($vvalue)
If ($iubounds - 1) > $iubound Then Return SetError(2, 0,
0)
If $idirection Then
For $i = $iubound To $iubounds Step -1
$aarray[$i] = $aarray[$i - $iubounds]
Next
For $i = 0 To $iubounds - 1
$aarray[$i] = $vvalue[$i]
Next
Else
For $i = 0 To $iubound - $iubounds
$aarray[$i] = $aarray[$i + $iubounds]
Next
For $i = 0 To $iubounds - 1
$aarray[$i + $iubound - $iubounds + 1] =
$vvalue[$i]
Next
EndIf
Else
If $iubound > -1 Then
If $idirection Then
For $i = $iubound To 1 Step -1
$aarray[$i] = $aarray[$i - 1]
Next
$aarray[0] = $vvalue
Else
For $i = 0 To $iubound - 1
$aarray[$i] = $aarray[$i + 1]
Next
$aarray[$iubound] = $vvalue
EndIf
EndIf
EndIf
Return 1
EndFunc
Func _arrayreverse(ByRef $aarray, $istart = 0, $iend = 0)
(3, 0, 0)
EndFunc
If
If
If
If
istep
If $aarr
Next
EndIf
If $brow Then
If $bcom
ptype AND VarGetType($aarray[$j][$i]) <> VarGetType($vvalue) Then ContinueLoop
If $aarr
ay[$j][$i] == $vvalue Then Return $i
Else
If $bcom
ptype AND VarGetType($aarray[$i][$j]) <> VarGetType($vvalue) Then ContinueLoop
If $aarr
ay[$i][$j] == $vvalue Then Return $i
EndIf
Next
EndIf
Else
For $i = $istart To $iend Step $
istep
If $icompare = 3 Then
If $brow Then
If Strin
gRegExp($aarray[$j][$i], $vvalue) Then Return $i
Else
If Strin
gRegExp($aarray[$i][$j], $vvalue) Then Return $i
EndIf
Else
If $brow Then
If Strin
gInStr($aarray[$j][$i], $vvalue, $icase) > 0 Then Return $i
Else
If Strin
gInStr($aarray[$i][$j], $vvalue, $icase) > 0 Then Return $i
EndIf
EndIf
Next
EndIf
Next
Case Else
Return SetError(2, 0, -1)
EndSwitch
Return SetError(6, 0, -1)
EndFunc
= -1)
rror(3, 0, -1)
(3, 0, -1)
__arraydualpivotsort($aarray, $istart, $
iend)
Else
nd)
art, $iend)
) - 1
0, 0)
EndIf
If $idescending Then _arrayreverse($aarray, $ist
Case 2
0)
$l += 1
WEnd
While ($aarray[$r] > $vpivot AND IsNumber($aarra
y[$r])) OR (NOT IsNumber($aarray[$r]) AND StringCompare($aarray[$r], $vpivot) >
0)
$r -= 1
WEnd
Else
While (StringCompare($aarray[$l], $vpivot) < 0)
$l += 1
WEnd
While (StringCompare($aarray[$r], $vpivot) > 0)
$r -= 1
WEnd
EndIf
If $l <= $r Then
$vtmp = $aarray[$l]
$aarray[$l] = $aarray[$r]
$aarray[$r] = $vtmp
$l += 1
$r -= 1
EndIf
Until $l > $r
__arrayquicksort1d($aarray, $istart, $r)
__arrayquicksort1d($aarray, $l, $iend)
EndFunc
Func __arrayquicksort2d(ByRef $aarray, Const ByRef $istep, Const ByRef $
istart, Const ByRef $iend, Const ByRef $isubitem, Const ByRef $isubmax)
If $iend <= $istart Then Return
Local $vtmp, $l = $istart, $r = $iend, $vpivot = $aarray[Int(($i
start + $iend) / 2)][$isubitem], $bnum = IsNumber($vpivot)
Do
If $bnum Then
While ($istep * ($aarray[$l][$isubitem] - $vpivo
t) < 0 AND IsNumber($aarray[$l][$isubitem])) OR (NOT IsNumber($aarray[$l][$isubi
tem]) AND $istep * StringCompare($aarray[$l][$isubitem], $vpivot) < 0)
$l += 1
WEnd
While ($istep * ($aarray[$r][$isubitem] - $vpivo
t) > 0 AND IsNumber($aarray[$r][$isubitem])) OR (NOT IsNumber($aarray[$r][$isubi
tem]) AND $istep * StringCompare($aarray[$r][$isubitem], $vpivot) > 0)
$r -= 1
WEnd
Else
While ($istep * StringCompare($aarray[$l][$isubi
tem], $vpivot) < 0)
$l += 1
WEnd
While ($istep * StringCompare($aarray[$r][$isubi
tem], $vpivot) > 0)
$r -= 1
WEnd
EndIf
If $l <= $r Then
For $i = 0 To $isubmax
$vtmp = $aarray[$l][$i]
$aarray[$l][$i] = $aarray[$r][$i]
$aarray[$r][$i] = $vtmp
Next
$l += 1
$r -= 1
EndIf
Until $l > $r
__arrayquicksort2d($aarray, $istep, $istart, $r, $isubitem, $isu
bmax)
ax)
$aarray[$k + 1] = $ia2
$ipivot_left += 1
WEnd
$ilast = $aarray[$ipivot_right]
$ipivot_right -= 1
While $ilast < $aarray[$ipivot_right]
$aarray[$ipivot_right + 1] = $aarray[$ip
ivot_right]
EndIf
Return 1
+ 1
$ipivot_right -= 1
WEnd
$aarray[$ipivot_right + 1] = $ilast
EndIf
Local $iseventh = BitShift($ilength, 3) + BitShift($ilength, 6)
Local $ie1, $ie2, $ie3, $ie4, $ie5, $t
$ie3 = Ceiling(($ipivot_left + $ipivot_right) / 2)
$ie2 = $ie3 - $iseventh
$ie1 = $ie2 - $iseventh
$ie4 = $ie3 + $iseventh
$ie5 = $ie4 + $iseventh
If $aarray[$ie2] < $aarray[$ie1] Then
$t = $aarray[$ie2]
$aarray[$ie2] = $aarray[$ie1]
$aarray[$ie1] = $t
EndIf
If $aarray[$ie3] < $aarray[$ie2] Then
$t = $aarray[$ie3]
$aarray[$ie3] = $aarray[$ie2]
$aarray[$ie2] = $t
If $t < $aarray[$ie1] Then
$aarray[$ie2] = $aarray[$ie1]
$aarray[$ie1] = $t
EndIf
EndIf
If $aarray[$ie4] < $aarray[$ie3] Then
$t = $aarray[$ie4]
$aarray[$ie4] = $aarray[$ie3]
$aarray[$ie3] = $t
If $t < $aarray[$ie2] Then
$aarray[$ie3] = $aarray[$ie2]
$aarray[$ie2] = $t
If $t < $aarray[$ie1] Then
$aarray[$ie2] = $aarray[$ie1]
$aarray[$ie1] = $t
EndIf
EndIf
EndIf
If $aarray[$ie5] < $aarray[$ie4] Then
$t = $aarray[$ie5]
$aarray[$ie5] = $aarray[$ie4]
$aarray[$ie4] = $t
If $t < $aarray[$ie3] Then
$aarray[$ie4] = $aarray[$ie3]
$aarray[$ie3] = $t
If $t < $aarray[$ie2] Then
$aarray[$ie3] = $aarray[$ie2]
$aarray[$ie2] = $t
If $t < $aarray[$ie1] Then
EndIf
EndIf
$aarray[$ie2] = $aarray[$ie1]
$aarray[$ie1] = $t
EndIf
EndIf
Local $iless = $ipivot_left
Local $igreater = $ipivot_right
If (($aarray[$ie1] <> $aarray[$ie2]) AND ($aarray[$ie2] <> $aarr
ay[$ie3]) AND ($aarray[$ie3] <> $aarray[$ie4]) AND ($aarray[$ie4] <> $aarray[$ie
5])) Then
Local $ipivot_1 = $aarray[$ie2]
Local $ipivot_2 = $aarray[$ie4]
$aarray[$ie2] = $aarray[$ipivot_left]
$aarray[$ie4] = $aarray[$ipivot_right]
Do
$iless += 1
Until $aarray[$iless] >= $ipivot_1
Do
$igreater -= 1
Until $aarray[$igreater] <= $ipivot_2
$k = $iless
While $k <= $igreater
$iak = $aarray[$k]
If $iak < $ipivot_1 Then
$aarray[$k] = $aarray[$iless]
$aarray[$iless] = $iak
$iless += 1
ElseIf $iak > $ipivot_2 Then
While $aarray[$igreater] > $ipivot_2
$igreater -= 1
If $igreater + 1 = $k Then ExitL
oop 2
WEnd
If $aarray[$igreater] < $ipivot_1 Then
$aarray[$k] = $aarray[$iless]
$aarray[$iless] = $aarray[$igrea
ter]
$iless += 1
Else
$aarray[$k] = $aarray[$igreater]
EndIf
$aarray[$igreater] = $iak
$igreater -= 1
EndIf
$k += 1
WEnd
$aarray[$ipivot_left] = $aarray[$iless - 1]
$aarray[$iless - 1] = $ipivot_1
$aarray[$ipivot_right] = $aarray[$igreater + 1]
$aarray[$igreater + 1] = $ipivot_2
__arraydualpivotsort($aarray, $ipivot_left, $iless - 2,
True)
__arraydualpivotsort($aarray, $igreater + 2, $ipivot_rig
ht, False)
If ($iless < $ie1) AND ($ie5 < $igreater) Then
While $aarray[$iless] = $ipivot_1
$iless += 1
WEnd
While $aarray[$igreater] = $ipivot_2
$igreater -= 1
WEnd
$k = $iless
While $k <= $igreater
$iak = $aarray[$k]
If $iak = $ipivot_1 Then
$aarray[$k] = $aarray[$iless]
$aarray[$iless] = $iak
$iless += 1
ElseIf $iak = $ipivot_2 Then
While $aarray[$igreater] = $ipiv
ot_2
$igreater -= 1
If $igreater + 1 = $k Th
en ExitLoop 2
WEnd
If $aarray[$igreater] = $ipivot_
1 Then
$aarray[$k] = $aarray[$i
less]
$aarray[$iless] = $ipivo
t_1
Else
greater]
EndIf
$k += 1
Else
ter]
$iless += 1
$aarray[$k] = $aarray[$i
EndIf
$aarray[$igreater] = $iak
$igreater -= 1
WEnd
EndIf
__arraydualpivotsort($aarray, $iless, $igreater, False)
Local $ipivot = $aarray[$ie3]
$k = $iless
While $k <= $igreater
If $aarray[$k] = $ipivot Then
$k += 1
ContinueLoop
EndIf
$iak = $aarray[$k]
If $iak < $ipivot Then
$aarray[$k] = $aarray[$iless]
$aarray[$iless] = $iak
$iless += 1
Else
While $aarray[$igreater] > $ipivot
$igreater -= 1
WEnd
If $aarray[$igreater] < $ipivot Then
$aarray[$k] = $aarray[$iless]
$aarray[$iless] = $aarray[$igrea
Else
$iless += 1
$aarray[$k] = $ipivot
EndIf
$aarray[$igreater] = $iak
EndIf
$k += 1
$igreater -= 1
WEnd
__arraydualpivotsort($aarray, $ipivot_left, $iless - 1,
True)
ht, False)
EndFunc
[$iindex_2][$j]
Next
EndFunc
$aarray[$iindex_2][$j] = $vtmp
EndIf
Case Else
Return SetError(2, 0, -1)
EndSwitch
Return 1
EndFunc
Case Else
Return SetError(2, 0, -1)
EndSwitch
Return 1
0, -1)
If
If
If
If
$iend =
$istart
$istart
$istart
0
>
<
>
Then $iend
$iend Then
0 OR $iend
$idim_1 OR
= $idim_1
Return SetError(3, 0, -1)
< 0 Then Return SetError(3, 0, -1)
$iend > $idim_1 Then Return SetError(3,
EndFunc
Next
__arrayunique_autoerrunregister()
Local $avalues, $j = 0
If $bcomerror Then
Return SetError(7, 0, 0)
ElseIf $iinttype <> $arrayunique_force32 Then
Local $avalues[$odictionary.count]
For $vkey In $odictionary.keys()
$avalues[$j] = $odictionary($vkey)
If StringLeft($vkey, 5) = "#Ptr#" Then
$avalues[$j] = Ptr($avalues[$j])
EndIf
$j += 1
Next
Else
$avalues = $odictionary.keys()
EndIf
If $icount Then
_arrayinsert($avalues, 0, $odictionary.count)
EndIf
Return $avalues
Else
EndIf
EndFunc
Next
Return $aarray
EndFunc
EndFunc
Func __array_greaterthan($vvalue1, $vvalue2)
Return $vvalue1 > $vvalue2
EndFunc
Func __array_lessthan($vvalue1, $vvalue2)
Return $vvalue1 < $vvalue2
EndFunc
Func __arrayunique_autoerrregister()
$g_oarrayuniquecomerrorhandler = ObjEvent("AutoIt.Error", "__Arr
ayUnique_AutoErrFunc")
EndFunc
Func __arrayunique_autoerrunregister()
$g_oarrayuniquecomerrorhandler = 0
EndFunc
Func __arrayunique_autoerrfunc()
EndFunc
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$hdf_left = 0
$hdf_right = 1
$hdf_center = 2
$hdf_justifymask = 3
$hdf_bitmap_on_right = 4096
$hdf_bitmap = 8192
$hdf_string = 16384
$hdf_ownerdraw = 32768
$hdf_displaymask = 61440
$hdf_rtlreading = 4
$hdf_sortdown = 512
$hdf_image = 2048
$hdf_sortup = 1024
$hdf_flagmask = 3588
$hdi_width = 1
$hdi_text = 2
$hdi_format = 4
$hdi_param = 8
$hdi_bitmap = 16
$hdi_image = 32
$hdi_di_setitem = 64
$hdi_order = 128
$hdi_filter = 256
$hht_nowhere = 1
$hht_onheader = 2
$hht_ondivider = 4
$hht_ondivopen = 8
$hht_onfilter = 16
$hht_onfilterbutton = 32
$hht_above = 256
$hht_below = 512
$hht_toright = 1024
$hht_toleft = 2048
$hdm_first = 4608
$hdm_clearfilter = $hdm_first + 24
$hdm_createdragimage = $hdm_first + 16
$hdm_deleteitem = $hdm_first + 2
$hdm_editfilter = $hdm_first + 23
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$hdm_getbitmapmargin = $hdm_first + 21
$hdm_getfocuseditem = $hdm_first + 27
$hdm_getimagelist = $hdm_first + 9
$hdm_getitema = $hdm_first + 3
$hdm_getitemw = $hdm_first + 11
$hdm_getitemcount = $hdm_first + 0
$hdm_getitemdropdownrect = $hdm_first + 25
$hdm_getitemrect = $hdm_first + 7
$hdm_getorderarray = $hdm_first + 17
$hdm_getoverflowrect = $hdm_first + 26
$hdm_getunicodeformat = 8192 + 6
$hdm_hittest = $hdm_first + 6
$hdm_insertitema = $hdm_first + 1
$hdm_insertitemw = $hdm_first + 10
$hdm_layout = $hdm_first + 5
$hdm_ordertoindex = $hdm_first + 15
$hdm_setbitmapmargin = $hdm_first + 20
$hdm_setfilterchangetimeout = $hdm_first + 22
$hdm_setfocuseditem = $hdm_first + 28
$hdm_sethotdivider = $hdm_first + 19
$hdm_setimagelist = $hdm_first + 8
$hdm_setitema = $hdm_first + 4
$hdm_setitemw = $hdm_first + 12
$hdm_setorderarray = $hdm_first + 18
$hdm_setunicodeformat = 8192 + 5
$hdn_first = -300
$hdn_begindrag = $hdn_first - 10
$hdn_begintrack = $hdn_first - 6
$hdn_dividerdblclick = $hdn_first - 5
$hdn_enddrag = $hdn_first - 11
$hdn_endtrack = $hdn_first - 7
$hdn_filterbtnclick = $hdn_first - 13
$hdn_filterchange = $hdn_first - 12
$hdn_getdispinfo = $hdn_first - 9
$hdn_itemchanged = $hdn_first - 1
$hdn_itemchanging = $hdn_first + 0
$hdn_itemclick = $hdn_first - 2
$hdn_itemdblclick = $hdn_first - 3
$hdn_track = $hdn_first - 8
$hdn_begintrackw = $hdn_first - 26
$hdn_dividerdblclickw = $hdn_first - 25
$hdn_endtrackw = $hdn_first - 27
$hdn_getdispinfow = $hdn_first - 29
$hdn_itemchangedw = $hdn_first - 21
$hdn_itemchangingw = $hdn_first - 20
$hdn_itemclickw = $hdn_first - 22
$hdn_itemdblclickw = $hdn_first - 23
$hdn_trackw = $hdn_first - 28
$hds_buttons = 2
$hds_checkboxes = 1024
$hds_dragdrop = 64
$hds_filterbar = 256
$hds_flat = 512
$hds_fulldrag = 128
$hds_hidden = 8
$hds_horz = 0
$hds_hottrack = 4
$hds_nosizing = 2048
$hds_overflow = 4096
$hds_default = 70
Global
Global
Global
Global
Global
Global
Global
$__g_hhdrlastwnd
Const $__headerconstant_classname = "SysHeader32"
Const $__headerconstant_default_gui_font = 17
Const $__headerconstant_swp_showwindow = 64
Const $taghdhittestinfo = $tagpoint & ";uint Flags;int Item"
Const $taghdlayout = "ptr Rect;ptr WindowPos"
Const $taghdtextfilter = "ptr Text;int TextMax"
lid)
Else
Else
EndFunc
<> 0
EndIf
$idestroyed = GUICtrlDelete($hwnd)
EndIf
If $idestroyed Then $hwnd = 0
Return $idestroyed <> 0
EndFunc
EndSwitch
Return -1
1)
R($iret, 2)
t, 4)
8)
EndFunc
Return $iret
et, 2)
, 4)
8)
EndFunc
Return $iret
EndFunc
r))
wparam", "struct*")
Else
ze($tbuffer), $tmemmap)
y, 0, "wparam", "ptr")
EndFunc
EndIf
Local $iflags = DllStructGetData($ttest, "Flags")
$atest[1] = BitAND($iflags, $hht_nowhere) <> 0
$atest[2] = BitAND($iflags, $hht_onheader) <> 0
$atest[3] = BitAND($iflags, $hht_ondivider) <> 0
$atest[4] = BitAND($iflags, $hht_ondivopen) <> 0
$atest[5] = BitAND($iflags, $hht_onfilter) <> 0
$atest[6] = BitAND($iflags, $hht_onfilterbutton) <> 0
$atest[7] = BitAND($iflags, $hht_above) <> 0
$atest[8] = BitAND($iflags, $hht_below) <> 0
$atest[9] = BitAND($iflags, $hht_toright) <> 0
$atest[10] = BitAND($iflags, $hht_toleft) <> 0
Return $atest
t))
$twindowpos))
", "struct*")
indowpos, $tmemmap)
out + $irect)
Local
Local
Local
Local
Local
$ilayout = DllStructGetSize($tlayout)
$irect = DllStructGetSize($trect)
$iwindowpos = DllStructGetSize($twindowpos)
$tmemmap
$pmemory = _meminit($hwnd, $ilayout + $irect + $iw
", "ptr")
wpos, $iwindowpos)
_memfree($tmemmap)
EndIf
Return $twindowpos
EndFunc
Func _guictrlheader_ordertoindex($hwnd, $iorder)
Return _sendmessage($hwnd, $hdm_ordertoindex, $iorder)
EndFunc
Func _guictrlheader_setbitmapmargin($hwnd, $iwidth)
Return _sendmessage($hwnd, $hdm_setbitmapmargin, $iwidth)
EndFunc
eout)
lue)
EndFunc
image)
rtlreading)
sortdown)
sortup)
EndFunc
served"
EndIf
For $ij = 1 To UBound($aitems, $ubound_c
DllStructSetData($titem, "SubIte
m", $ij)
DllStructSetData($tbuffer, "Text
", $aitems[$ii][$ij])
mory, $iitem)
_memwrite($tmemmap, $tbuffer, $p
text, $ibuffer)
_setitemw, 0, $pmemory, 0, "wparam", "ptr")
_setitema, 0, $pmemory, 0, "wparam", "ptr")
Next
Else
m)
EndIf
If $bunicode Then
_sendmessage($hwnd, $lvm
Else
_sendmessage($hwnd, $lvm
EndIf
Next
_memfree($tmemmap)
0])
0, $pitem)
0, $pitem)
- 1
If $bunicode Then
GUICtrlSendMsg($hwnd, $lvm_insertitemw,
Else
EndIf
For $ij = 1 To UBound($aitems, $ubound_columns)
DllStructSetData($titem, "SubItem", $ij)
DllStructSetData($tbuffer, "Text", $aite
ms[$ii][$ij])
If $bunicode Then
GUICtrlSendMsg($hwnd, $lvm_setit
emw, 0, $pitem)
Else
ema, 0, $pitem)
Next
EndFunc
GUICtrlSendMsg($hwnd, $lvm_insertitema,
GUICtrlSendMsg($hwnd, $lvm_setit
EndIf
Next
EndIf
_guictrllistview_endupdate($hwnd)
Func _guictrllistview_addcolumn($hwnd, $stext, $iwidth = 50, $ialign = 1, $iimage = -1, $bonright = False)
Return _guictrllistview_insertcolumn($hwnd, _guictrllistview_get
columncount($hwnd), $stext, $iwidth, $ialign, $iimage, $bonright)
EndFunc
iparam)
$pitem)
EndFunc
EndIf
EndIf
Return $iret <> 0
If $iupper = 1 Then
SetError(2)
Return ""
EndIf
Local $avnewarray[$iupper - 1][$__g_illistviewsortinfosize]
$avnewarray[0][0] = $avarray[0][0]
If $ielement < 0 Then
$ielement = 0
EndIf
If $ielement > ($iupper - 1) Then
$ielement = ($iupper - 1)
EndIf
If $ielement > 0 Then
For $icntr = 0 To $ielement - 1
For $x = 1 To $__g_illistviewsortinfosize - 1
$avnewarray[$icntr][$x] = $avarray[$icnt
r][$x]
Next
icntr][$x]
EndIf
If $ielement < ($iupper - 1) Then
For $icntr = ($ielement + 1) To ($iupper - 1)
For $x = 1 To $__g_illistviewsortinfosize - 1
$avnewarray[$icntr - 1][$x] = $avarray[$
Next
EndFunc
se) = 0
Next
Next
EndIf
$avarray = $avnewarray
SetError(0)
Return 1
Func _guictrllistview_beginupdate($hwnd)
If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
Return _sendmessage($hwnd, $__listviewconstant_wm_setredraw, Fal
EndFunc
Func _guictrllistview_canceleditlabel($hwnd)
If IsHWnd($hwnd) Then
_sendmessage($hwnd, $lvm_canceleditlabel)
Else
GUICtrlSendMsg($hwnd, $lvm_canceleditlabel, 0, 0)
EndIf
EndFunc
Else
EndFunc
_winapi_showcursor(False)
MouseClick($sbutton, $ix, $iy, $iclicks, $ispeed)
MouseMove($apos[0], $apos[1], 0)
_winapi_showcursor(True)
d_source, $a_indices[$i])
If $bdelflag Then
For $i = $a_indices[0] To 1 Step -1
_guictrllistview_deleteitem($hwn
EndIf
ource, 1)
Next
EndIf
EndIf
If (_guictrllistview_getselectedcount($hwnd_source)) Then
$a_indices = _guictrllistview_getselectedindices($hwnd_s
For $i = 1 To $a_indices[0]
DllStructSetData($titem, "Mask", BitOR($lvif_gro
upid, $lvif_image, $lvif_indent, $lvif_param, $lvif_state))
DllStructSetData($titem, "Item", $a_indices[$i])
DllStructSetData($titem, "SubItem", 0)
DllStructSetData($titem, "StateMask", -1)
_guictrllistview_getitemex($hwnd_source, $titem)
$iindex = _guictrllistview_additem($hwnd_destina
tion, _guictrllistview_getitemtext($hwnd_source, $a_indices[$i], 0), DllStructGe
tData($titem, "Image"))
For $x = 1 To $icols - 1
DllStructSetData($titem, "Item", $a_indi
ces[$i])
DllStructSetData($titem, "SubItem", $x)
_guictrllistview_getitemex($hwnd_source,
$titem)
_guictrllistview_addsubitem($hwnd_destin
ation, $iindex, _guictrllistview_getitemtext($hwnd_source, $a_indices[$i], $x),
$x, DllStructGetData($titem, "Image"))
Next
Next
_guictrllistview_setitemselected($hwnd_source, -1, False
)
If $bdelflag Then
For $i = $a_indices[0] To 1 Step -1
_guictrllistview_deleteitem($hwnd_source
, $a_indices[$i])
Next
EndIf
EndIf
_guictrllistview_endupdate($hwnd_source)
_guictrllistview_endupdate($hwnd_destination)
EndFunc
Func _guictrllistview_create($hwnd, $sheadertext, $ix, $iy, $iwidth = 15
0, $iheight = 150, $istyle = 13, $iexstyle = 0, $bcoinit = False)
If NOT IsHWnd($hwnd) Then Return SetError(1, 0, 0)
If NOT IsString($sheadertext) Then Return SetError(2, 0, 0)
If $iwidth = -1 Then $iwidth = 150
If $iheight = -1 Then $iheight = 150
If $istyle = -1 Then $istyle = $lvs_default
If $iexstyle = -1 Then $iexstyle = 0
Local Const $s_ok = 0
Local Const $s_false = 1
Local Const $rpc_e_changed_mode = -2147417850
Local Const $e_invalidarg = -2147024809
Local Const $e_outofmemory = -2147024882
Local Const $e_unexpected = -2147418113
Local $sseparatorchar = Opt("GUIDataSeparatorChar")
aratorchar)
t)
ht)
Func _guictrllistview_deleteallitems($hwnd)
If _guictrllistview_getitemcount($hwnd) = 0 Then Return True
Local $vcid = 0
If IsHWnd($hwnd) Then
$vcid = _winapi_getdlgctrlid($hwnd)
Else
$vcid = $hwnd
$hwnd = GUICtrlGetHandle($hwnd)
EndIf
If $vcid < $_udf_startid Then
Local $iparam = 0
For $iindex = _guictrllistview_getitemcount($hwnd) - 1 T
o 0 Step -1
$iparam = _guictrllistview_getitemparam($hwnd, $
iindex)
If GUICtrlGetState($iparam) > 0 AND GUICtrlGetHa
ndle($iparam) = 0 Then
GUICtrlDelete($iparam)
EndIf
Next
If _guictrllistview_getitemcount($hwnd) = 0 Then Return
True
EndIf
Return _sendmessage($hwnd, $lvm_deleteallitems) <> 0
EndFunc
) <> 0
EndFunc
ndex)
EndIf
aram) = 0 Then
EndIf
If GUICtrlDelete($iparam) Then
Return True
EndIf
EndFunc
EndIf
Return _sendmessage($hwnd, $lvm_deleteitem, $iindex) <> 0
Func _guictrllistview_deleteitemsselected($hwnd)
Local $iitemcount = _guictrllistview_getitemcount($hwnd)
If _guictrllistview_getselectedcount($hwnd) = $iitemcount Then
Return _guictrllistview_deleteallitems($hwnd)
Else
Local $aselected = _guictrllistview_getselectedindices($
hwnd, True)
If NOT IsArray($aselected) Then Return SetError($lv_err,
$lv_err, 0)
_guictrllistview_setitemselected($hwnd, -1, False)
Local $vcid = 0, $inative_delete, $iudf_delete
If IsHWnd($hwnd) Then
$vcid = _winapi_getdlgctrlid($hwnd)
Else
$vcid = $hwnd
$hwnd = GUICtrlGetHandle($hwnd)
EndIf
For $iindex = $aselected[0] To 1 Step -1
If $vcid < $_udf_startid Then
Local $iparam = _guictrllistview_getitem
param($hwnd, $aselected[$iindex])
If GUICtrlGetState($iparam) > 0 AND GUIC
trlGetHandle($iparam) = 0 Then
$inative_delete = GUICtrlDelete(
$iparam)
If $inative_delete Then Continue
Loop
EndIf
EndIf
$iudf_delete = _sendmessage($hwnd, $lvm_deleteit
em, $aselected[$iindex])
If $inative_delete + $iudf_delete = 0 Then
ExitLoop
EndIf
Next
Return NOT $iindex
EndIf
EndFunc
Func _guictrllistview_destroy(ByRef $hwnd)
If NOT _winapi_isclassname($hwnd, $__listviewconstant_classname)
Then Return SetError(2, 2, False)
Local $idestroyed = 0
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
Local $nctrlid = _winapi_getdlgctrlid($hwnd)
Local $hparent = _winapi_getparent($hwnd)
$idestroyed = _winapi_destroywindow($hwnd)
Local $iret = __udf_freeglobalid($hparent, $nctr
lid)
If NOT $iret Then
EndIf
Else
Return SetError(1, 1, False)
EndIf
Else
EndFunc
$idestroyed = GUICtrlDelete($hwnd)
EndIf
If $idestroyed Then $hwnd = 0
Return $idestroyed <> 0
EndFunc
e)
ble, 0)
EndFunc
e) = 0
EndIf
Func _guictrllistview_endupdate($hwnd)
If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
Return _sendmessage($hwnd, $__listviewconstant_wm_setredraw, Tru
EndFunc
rn $ii
Else
Next
rn $ii
Next
EndFunc
= "")
Next
Next
EndIf
Return -1
EndFunc
1)
Func _guictrllistview_getcallbackmask($hwnd)
Local $iflags = 0
Local $imask = _sendmessage($hwnd, $lvm_getcallbackmask)
If BitAND($imask, $lvis_cut) <> 0 Then $iflags = BitOR($iflags,
iflags, 2)
gs, 4)
ags, 8)
iflags, 16)
R($iflags, 32)
EndFunc
Else
0)
EndFunc
EndIf
Func _guictrllistview_getcounterpage($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getcountperpage)
Else
Return GUICtrlSendMsg($hwnd, $lvm_getcountperpage, 0, 0)
EndIf
EndFunc
, 0))
Func _guictrllistview_geteditcontrol($hwnd)
If IsHWnd($hwnd) Then
Return HWnd(_sendmessage($hwnd, $lvm_geteditcontrol))
Else
Return HWnd(GUICtrlSendMsg($hwnd, $lvm_geteditcontrol, 0
EndFunc
EndIf
Func _guictrllistview_getemptytext($hwnd)
Local $ttext = DllStructCreate("char[4096]")
Local $iret
If IsHWnd($hwnd) Then
Local $itext = DllStructGetSize($ttext)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $itext + 4096, $tmemmap
Local $ptext = $pmemory + $itext
DllStructSetData($ttext, "Text", $ptext)
_memwrite($tmemmap, $ptext, $pmemory, $itext)
$iret = _sendmessage($hwnd, $lvm_getemptytext, 4096, $pm
emory)
Else
llStructGetPtr($ttext))
EndFunc
EndIf
Func _guictrllistview_getextendedlistviewstyle($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getextendedlistviewstyle
Else
le, 0, 0)
EndFunc
EndIf
Func _guictrllistview_getfocusedgroup($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getfocusedgroup)
Else
Return GUICtrlSendMsg($hwnd, $lvm_getfocusedgroup, 0, 0)
EndFunc
EndIf
Func _guictrllistview_getgroupcount($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getgroupcount)
Else
Return GUICtrlSendMsg($hwnd, $lvm_getgroupcount, 0, 0)
EndIf
EndFunc
Func _guictrllistview_getgroupinfo($hwnd, $igroupid)
Local $tgroup = __guictrllistview_getgroupinfoex($hwnd, $igroupi
d, BitOR($lvgf_header, $lvgf_align))
Local $ierr = @error
Local $agroup[2]
$agroup[0] = _winapi_widechartomultibyte(DllStructGetData($tgrou
p, "Header"))
Select
Case BitAND(DllStructGetData($tgroup, "Align"), $lvga_he
ader_center) <> 0
$agroup[1] = 1
Case BitAND(DllStructGetData($tgroup, "Align"), $lvga_he
ader_right) <> 0
$agroup[1] = 2
Case Else
$agroup[1] = 0
EndSelect
Return SetError($ierr, 0, $agroup)
EndFunc
Func __guictrllistview_getgroupinfoex($hwnd, $igroupid, $imask)
Local $tgroup = DllStructCreate($taglvgroup)
Local $igroup = DllStructGetSize($tgroup)
DllStructSetData($tgroup, "Size", $igroup)
DllStructSetData($tgroup, "Mask", $imask)
Local $iret
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
$iret = _sendmessage($hwnd, $lvm_getgroupinfo, $
igroupid, $tgroup, 0, "wparam", "struct*")
Else
Local $tmemmap
Local $pmemory = _meminit($hwnd, $igroup, $tmemm
ap)
_memwrite($tmemmap, $tgroup, $pmemory, $igroup)
$iret = _sendmessage($hwnd, $lvm_getgroupinfo, $
igroupid, $pmemory, 0, "wparam", "ptr")
_memread($tmemmap, $pmemory, $tgroup, $igroup)
_memfree($tmemmap)
EndIf
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_getgroupinfo, $igroup
id, DllStructGetPtr($tgroup))
EndIf
Return SetError($iret <> $igroupid, 0, $tgroup)
EndFunc
Func _guictrllistview_getgroupinfobyindex($hwnd, $iindex)
Local $tgroup = DllStructCreate($taglvgroup)
Else
EndFunc
e]
EndIf
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getimagelist, $aimagelis
t[$iimagelist], 0, 0, "wparam", "lparam", "handle")
Else
Return Ptr(GUICtrlSendMsg($hwnd, $lvm_getimagelist, $aim
agelist[$iimagelist], 0))
EndIf
EndFunc
Func _guictrllistview_getinsertmark($hwnd)
Local $tmark = DllStructCreate($taglvinsertmark)
Local $imark = DllStructGetSize($tmark)
DllStructSetData($tmark, "Size", $imark)
Local $iret
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
$iret = _sendmessage($hwnd, $lvm_getinsertmark,
0, $tmark, 0, "wparam", "struct*")
Else
Local $tmemmap
Local $pmemory = _meminit($hwnd, $imark, $tmemma
p)
_memwrite($tmemmap, $tmark)
$iret = _sendmessage($hwnd, $lvm_getinsertmark,
0, $pmemory, 0, "wparam", "ptr")
_memread($tmemmap, $pmemory, $tmark, $imark)
_memfree($tmemmap)
EndIf
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_getinsertmark, 0, Dll
StructGetPtr($tmark))
EndIf
Local $amark[2]
$amark[0] = DllStructGetData($tmark, "Flags") = $lvim_after
$amark[1] = DllStructGetData($tmark, "Item")
Return SetError($iret = 0, 0, $amark)
EndFunc
Func _guictrllistview_getinsertmarkcolor($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getinsertmarkcolor, $lvs
il_state)
Else
Return GUICtrlSendMsg($hwnd, $lvm_getinsertmarkcolor, $l
vsil_state, 0)
EndIf
EndFunc
Func _guictrllistview_getinsertmarkrect($hwnd)
Local $arect[5]
Local $trect = DllStructCreate($tagrect)
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
map)
If $bunicode Then
_sendmessage($hwnd, $lvm_getisearchstrin
gw, 0, $pmemory)
Else
ga, 0, $pmemory)
Else
$pbuffer)
$pbuffer)
EndFunc
EndIf
_sendmessage($hwnd, $lvm_getisearchstrin
EndIf
_memread($tmemmap, $pmemory, $tbuffer, $ibuffer)
_memfree($tmemmap)
GUICtrlSendMsg($hwnd, $lvm_getisearchstringa, 0,
EndIf
EndIf
Return DllStructGetData($tbuffer, "Text")
<> 0
Else
p)
Else
$pitem)
EndIf
EndFunc
_memwrite($tmemmap, $titem)
If $bunicode Then
_sendmessage($hwnd, $lvm_getitemw, 0, $p
Else
_sendmessage($hwnd, $lvm_getitema, 0, $p
EndIf
_memread($tmemmap, $pmemory, $titem, $iitem)
_memfree($tmemmap)
$pitem)
EndIf
EndIf
Return $iret <> 0
part)
EndFunc
Local $arect[4]
$arect[0] = DllStructGetData($trect,
$arect[1] = DllStructGetData($trect,
$arect[2] = DllStructGetData($trect,
$arect[3] = DllStructGetData($trect,
Return $arect
"Left")
"Top")
"Right")
"Bottom")
ll)
mall, 0)
EndFunc
EndIf
Local $aspace[2]
$aspace[0] = BitAND($ispace, 65535)
$aspace[1] = BitShift($ispace, 16)
Return $aspace
imask)
$imask)
EndFunc
EndIf
, $pitem)
, $pitem)
EndFunc
Else
EndIf
EndIf
Return DllStructGetData($tbuffer, "Text")
EndFunc
_sendmessage($hwnd, $lvm_getnumberofworkareas, 0
, $tbuffer, 0, "wparam", "struct*")
Else
Local $ibuffer = DllStructGetSize($tbuffer)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $ibuffer, $tmem
map)
_sendmessage($hwnd, $lvm_getnumberofworkareas, 0
, $pmemory, 0, "wparam", "ptr")
_memread($tmemmap, $pmemory, $tbuffer, $ibuffer)
_memfree($tmemmap)
EndIf
Else
GUICtrlSendMsg($hwnd, $lvm_getnumberofworkareas, 0, DllS
tructGetPtr($tbuffer))
EndIf
Return DllStructGetData($tbuffer, "Data")
EndFunc
Func _guictrllistview_getorigin($hwnd)
Local $tpoint = DllStructCreate($tagpoint)
Local $iret
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
$iret = _sendmessage($hwnd, $lvm_getorigin, 0, $
tpoint, 0, "wparam", "struct*")
Else
Local $ipoint = DllStructGetSize($tpoint)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $ipoint, $tmemm
ap)
$iret = _sendmessage($hwnd, $lvm_getorigin, 0, $
pmemory, 0, "wparam", "ptr")
_memread($tmemmap, $pmemory, $tpoint, $ipoint)
_memfree($tmemmap)
EndIf
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_getorigin, 0, DllStru
ctGetPtr($tpoint))
EndIf
Local $aorigin[2]
$aorigin[0] = DllStructGetData($tpoint, "X")
$aorigin[1] = DllStructGetData($tpoint, "Y")
Return SetError(@error, $iret = 1, $aorigin)
EndFunc
Func _guictrllistview_getoriginx($hwnd)
Local $aorigin = _guictrllistview_getorigin($hwnd)
Return $aorigin[0]
EndFunc
Func _guictrllistview_getoriginy($hwnd)
Local $aorigin = _guictrllistview_getorigin($hwnd)
Return $aorigin[1]
EndFunc
Func _guictrllistview_getoutlinecolor($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getoutlinecolor)
Else
EndFunc
0)
Func _guictrllistview_getselectedcolumn($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getselectedcolumn)
Else
Return GUICtrlSendMsg($hwnd, $lvm_getselectedcolumn, 0,
EndFunc
EndIf
EndIf
Func _guictrllistview_getselectedcount($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getselectedcount)
Else
Return GUICtrlSendMsg($hwnd, $lvm_getselectedcount, 0, 0
EndFunc
EndIf
Func __guictrllistview_getcheckedindices($hwnd)
Local $icount = _guictrllistview_getitemcount($hwnd)
Local $aselected[$icount + 1] = [0]
For $i = 0 To $icount - 1
If _guictrllistview_getitemchecked($hwnd, $i) Then
$aselected[0] += 1
$aselected[$aselected[0]] = $i
EndIf
Next
ReDim $aselected[$aselected[0] + 1]
Return $aselected
EndFunc
Func _guictrllistview_getselectedindices($hwnd, $barray = False)
Local $sindices, $aindices[1] = [0]
Local $iret, $icount = _guictrllistview_getitemcount($hwnd)
For $iitem = 0 To $icount
If IsHWnd($hwnd) Then
$iret = _sendmessage($hwnd, $lvm_getitemstate, $
iitem, $lvis_selected)
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_getitemstate,
$iitem, $lvis_selected)
EndIf
If $iret Then
If (NOT $barray) Then
If StringLen($sindices) Then
$sindices &= "|" & $iitem
Else
$sindices = $iitem
EndIf
Else
ReDim $aindices[UBound($aindices) + 1]
$aindices[0] = UBound($aindices) - 1
$aindices[UBound($aindices) - 1] = $iite
m
EndIf
EndIf
EndFunc
Func _guictrllistview_getselectionmark($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getselectionmark)
Else
Return GUICtrlSendMsg($hwnd, $lvm_getselectionmark, 0, 0
EndFunc
")
Next
If (NOT $barray) Then
Return String($sindices)
Else
Return $aindices
EndIf
EndIf
$ibuffer *= 2
$tbuffer = DllStructCreate("char Text[" & $ibuffer & "]"
EndIf
DllStructSetData($tbuffer, "Text", $sstring)
Local $iret
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
$iret = _sendmessage($hwnd, $lvm_getstringwidthw
, 0, $tbuffer, 0, "wparam", "struct*")
Else
Local $tmemmap
Local $pmemory = _meminit($hwnd, $ibuffer, $tmem
map)
_memwrite($tmemmap, $tbuffer, $pmemory, $ibuffer
)
If $bunicode Then
$iret = _sendmessage($hwnd, $lvm_getstri
ngwidthw, 0, $pmemory, 0, "wparam", "ptr")
Else
$iret = _sendmessage($hwnd, $lvm_getstri
ngwidtha, 0, $pmemory, 0, "wparam", "ptr")
EndIf
_memread($tmemmap, $pmemory, $tbuffer, $ibuffer)
_memfree($tmemmap)
EndIf
Else
Local $pbuffer = DllStructGetPtr($tbuffer)
If $bunicode Then
$iret = GUICtrlSendMsg($hwnd, $lvm_getstringwidt
hw, 0, $pbuffer)
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_getstringwidt
ha, 0, $pbuffer)
EndIf
EndFunc
0)
EndIf
Return $iret
))
Func _guictrllistview_gettooltips($hwnd)
If IsHWnd($hwnd) Then
Return HWnd(_sendmessage($hwnd, $lvm_gettooltips))
Else
Return HWnd(GUICtrlSendMsg($hwnd, $lvm_gettooltips, 0, 0
EndIf
EndFunc
Func _guictrllistview_gettopindex($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_gettopindex)
Else
Return GUICtrlSendMsg($hwnd, $lvm_gettopindex, 0, 0)
EndIf
EndFunc
) <> 0
Func _guictrllistview_getunicodeformat($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_getunicodeformat) <> 0
Else
Return GUICtrlSendMsg($hwnd, $lvm_getunicodeformat, 0, 0
EndFunc
EndIf
Func _guictrllistview_getview($hwnd)
Local $iview
If IsHWnd($hwnd) Then
$iview = _sendmessage($hwnd, $lvm_getview)
Else
$iview = GUICtrlSendMsg($hwnd, $lvm_getview, 0, 0)
EndIf
Switch $iview
Case $lv_view_icon
Return Int($lv_view_icon)
Case $lv_view_details
Return Int($lv_view_details)
Case $lv_view_list
Return Int($lv_view_list)
Case $lv_view_smallicon
Return Int($lv_view_smallicon)
Case $lv_view_tile
Return Int($lv_view_tile)
Case Else
Return -1
EndSwitch
EndFunc
Func _guictrllistview_getviewdetails($hwnd)
Return _guictrllistview_getview($hwnd) = $lv_view_details
EndFunc
Func _guictrllistview_getviewlarge($hwnd)
Return _guictrllistview_getview($hwnd) = $lv_view_icon
EndFunc
Func _guictrllistview_getviewlist($hwnd)
Return _guictrllistview_getview($hwnd) = $lv_view_list
EndFunc
Func _guictrllistview_getviewsmall($hwnd)
Return _guictrllistview_getview($hwnd) = $lv_view_smallicon
EndFunc
Func _guictrllistview_getviewtile($hwnd)
Return _guictrllistview_getview($hwnd) = $lv_view_tile
EndFunc
Func _guictrllistview_getviewrect($hwnd)
Local $arect[4] = [0, 0, 0, 0]
Local $iview = _guictrllistview_getview($hwnd)
If ($iview <> 1) AND ($iview <> 3) Then Return $arect
Local $trect = DllStructCreate($tagrect)
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
_sendmessage($hwnd, $lvm_getviewrect, 0, $trect,
0, "wparam", "struct*")
Else
Local $irect = DllStructGetSize($trect)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $irect, $tmemma
p)
_sendmessage($hwnd, $lvm_getviewrect, 0, $pmemor
y, 0, "wparam", "ptr")
_memread($tmemmap, $pmemory, $trect, $irect)
_memfree($tmemmap)
EndIf
Else
GUICtrlSendMsg($hwnd, $lvm_getviewrect, 0, DllStructGetP
tr($trect))
EndIf
$arect[0] = DllStructGetData($trect, "Left")
$arect[1] = DllStructGetData($trect, "Top")
$arect[2] = DllStructGetData($trect, "Right")
$arect[3] = DllStructGetData($trect, "Bottom")
Return $arect
EndFunc
> 0
0) <> 0
EndFunc
EndIf
ge)
EndIf
If $bonright Then $ifmt = BitOR($ifmt, $lvcfmt_bitmap_on_right)
DllStructSetData($tbuffer, "Text", $stext)
DllStructSetData($tcolumn, "Mask", $imask)
DllStructSetData($tcolumn, "Fmt", $ifmt)
DllStructSetData($tcolumn, "CX", $iwidth)
DllStructSetData($tcolumn, "TextMax", $ibuffer)
DllStructSetData($tcolumn, "Image", $iimage)
Local $iret
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
DllStructSetData($tcolumn, "Text", $pbuffer)
$iret = _sendmessage($hwnd, $lvm_insertcolumnw,
$iindex, $tcolumn, 0, "wparam", "struct*")
Else
Local $icolumn = DllStructGetSize($tcolumn)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $icolumn + $ibu
ffer, $tmemmap)
Local $ptext = $pmemory + $icolumn
DllStructSetData($tcolumn, "Text", $ptext)
_memwrite($tmemmap, $tcolumn, $pmemory, $icolumn
)
_memwrite($tmemmap, $tbuffer, $ptext, $ibuffer)
If $bunicode Then
$iret = _sendmessage($hwnd, $lvm_insertc
olumnw, $iindex, $pmemory, 0, "wparam", "ptr")
Else
$iret = _sendmessage($hwnd, $lvm_insertc
olumna, $iindex, $pmemory, 0, "wparam", "ptr")
EndIf
_memfree($tmemmap)
EndIf
Else
Local $pcolumn = DllStructGetPtr($tcolumn)
DllStructSetData($tcolumn, "Text", $pbuffer)
If $bunicode Then
$iret = GUICtrlSendMsg($hwnd, $lvm_insertcolumnw
, $iindex, $pcolumn)
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_insertcolumna
, $iindex, $pcolumn)
EndIf
EndIf
If $ialign > 0 Then _guictrllistview_setcolumn($hwnd, $iret, $st
ext, $iwidth, $ialign, $iimage, $bonright)
Return $iret
EndFunc
Func _guictrllistview_insertgroup($hwnd, $iindex, $igroupid, $sheader, $
ialign = 0)
Local $aalign[3] = [$lvga_header_left, $lvga_header_center, $lvg
a_header_right]
If $ialign < 0 OR $ialign > 2 Then $ialign = 0
Local $theader = _winapi_multibytetowidechar($sheader)
Local $pheader = DllStructGetPtr($theader)
Local $iheader = StringLen($sheader)
Local $tgroup = DllStructCreate($taglvgroup)
er, $tmemmap)
Else
EndIf
<> 0
, 0) <> 0
EndFunc
EndIf
iindex, $pcolumn)
iindex, $pcolumn)
EndFunc
If $bunicode Then
$iret = GUICtrlSendMsg($hwnd, $lvm_setcolumnw, $
Else
EndIf
EndIf
Return $iret <> 0
0)
index)
EndIf
$iindex)
EndFunc
EndIf
Func __guictrllistview_overlayimagemasktoindex($imask)
Return BitShift(BitAND($lvis_overlaymask, $imask), 8)
EndFunc
Func _guictrllistview_redrawitems($hwnd, $ifirst, $ilast)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $lvm_redrawitems, $ifirst, $i
last) <> 0
Else
Return GUICtrlSendMsg($hwnd, $lvm_redrawitems, $ifirst,
$ilast) <> 0
EndIf
EndFunc
Func _guictrllistview_registersortcallback($hwnd, $bnumbers = True, $bar
rows = True)
If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
Local $hheader = _guictrllistview_getheader($hwnd)
ReDim $__g_alistviewsortinfo[UBound($__g_alistviewsortinfo) + 1]
[$__g_illistviewsortinfosize]
$__g_alistviewsortinfo[0][0] = UBound($__g_alistviewsortinfo) 1
, 0)
EndIf
Func __guictrllistview_reversecolororder($icolor)
Local $sh = Hex(String($icolor), 6)
Return "0x" & StringMid($sh, 5, 2) & StringMid($sh, 3, 2) & Stri
ngMid($sh, 1, 2)
EndFunc
r)
EndIf
EndFunc
_winapi_invalidaterect(GUICtrlGetHandle($hwnd))
EndIf
Return $iret <> 0
EndFunc
t)
ophilited)
cused)
lected)
verlaymask)
tateimagemask)
) <> 0
gs, 0) <> 0
EndFunc
EndIf
map)
iwidth)
$iwidth)
EndFunc
k = 0)
EndIf
Local $iret
If IsHWnd($hwnd) Then
$iret = _sendmessage($hwnd, $lvm_setextendedlistviewstyl
e, $iexmask, $iexstyle)
_winapi_invalidaterect($hwnd)
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_setextendedlistviewst
yle, $iexmask, $iexstyle)
_winapi_invalidaterect(GUICtrlGetHandle($hwnd))
EndIf
Return $iret
EndFunc
Func _guictrllistview_setgroupinfo($hwnd, $igroupid, $sheader, $ialign =
0, $istate = $lvgs_normal)
Local $tgroup = 0
If BitAND($istate, $lvgs_selected) Then
$tgroup = __guictrllistview_getgroupinfoex($hwnd, $igrou
pid, BitOR($lvgf_groupid, $lvgf_items))
If DllStructGetData($tgroup, "GroupId") <> $igroupid OR
DllStructGetData($tgroup, "cItems") = 0 Then Return False
EndIf
Local $aalign[3] = [$lvga_header_left, $lvga_header_center, $lvg
a_header_right]
If $ialign < 0 OR $ialign > 2 Then $ialign = 0
Local $theader = _winapi_multibytetowidechar($sheader)
Local $pheader = DllStructGetPtr($theader)
Local $iheader = StringLen($sheader)
$tgroup = DllStructCreate($taglvgroup)
Local $pgroup = DllStructGetPtr($tgroup)
Local $igroup = DllStructGetSize($tgroup)
Local $imask = BitOR($lvgf_header, $lvgf_align, $lvgf_state)
DllStructSetData($tgroup, "Size", $igroup)
DllStructSetData($tgroup, "Mask", $imask)
EndFunc
e)
EndIf
EndIf
uctGetPtr($tinfo))
EndIf
Return $iret <> 0
EndFunc
icolor)
$icolor)
EndFunc
EndIf
Else
EndFunc
$ibuffer = 0
$pbuffer = -1
EndIf
Local $titem = DllStructCreate($taglvitem)
Local $imask = $lvif_text
If $iimage <> -1 Then $imask = BitOR($imask, $lvif_image)
If $iparam <> -1 Then $imask = BitOR($imask, $lvif_param)
If $iindent <> -1 Then $imask = BitOR($imask, $lvif_indent)
DllStructSetData($titem, "Mask", $imask)
DllStructSetData($titem, "Item", $iindex)
DllStructSetData($titem, "SubItem", $isubitem)
DllStructSetData($titem, "Text", $pbuffer)
DllStructSetData($titem, "TextMax", $ibuffer)
DllStructSetData($titem, "Image", $iimage)
DllStructSetData($titem, "Param", $iparam)
DllStructSetData($titem, "Indent", $iindent)
Return _guictrllistview_setitemex($hwnd, $titem)
wnd) Then
EndIf
EndIf
For $x = 0 To _guictrllistview_getitemcount($hwnd) - 1
DllStructSetData($titem, "Mask", $lvif_state)
DllStructSetData($titem, "Item", $x)
If ($bcheck) Then
DllStructSetData($titem, "State", 8192)
Else
DllStructSetData($titem, "State", 4096)
EndIf
DllStructSetData($titem, "StateMask", 61440)
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlast
Local $istate = 0
If $benabled Then $istate = $lvis_drophilited
Return _guictrllistview_setitemstate($hwnd, $iindex, $istate, $l
vis_drophilited)
EndFunc
mmap)
xt, $ibuffer)
If $bunicode Then
$iret = _sendmessage($hwnd, $lvm_setitemw, 0, $p
memory, 0, "wparam", "ptr")
Else
$iret = _sendmessage($hwnd, $lvm_setitema, 0, $p
memory, 0, "wparam", "ptr")
EndIf
_memfree($tmemmap)
Else
Local $pitem = DllStructGetPtr($titem)
If $bunicode Then
$iret = GUICtrlSendMsg($hwnd, $lvm_setitemw, 0,
$pitem)
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_setitema, 0,
$pitem)
EndIf
EndIf
Return $iret <> 0
EndFunc
Func _guictrllistview_setitemfocused($hwnd, $iindex, $benabled = True)
Local $istate = 0
If $benabled Then $istate = $lvis_focused
Return _guictrllistview_setitemstate($hwnd, $iindex, $istate, $l
vis_focused)
EndFunc
Func _guictrllistview_setitemgroupid($hwnd, $iindex, $igroupid)
EndFunc
0)
EndFunc
ap)
_memwrite($tmemmap, $tpoint)
$iret = _sendmessage($hwnd, $lvm_setitemposition
32, $iindex, $pmemory, 0, "wparam", "ptr")
_memfree($tmemmap)
EndIf
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_setitemposition32, $i
index, DllStructGetPtr($tpoint))
EndIf
Return $iret <> 0
EndFunc
Func _guictrllistview_setitemselected($hwnd, $iindex, $bselected = True,
$bfocused = False)
Local $tstruct = DllStructCreate($taglvitem)
Local $iret, $iselected = 0, $ifocused = 0, $isize, $tmemmap, $p
memory
If ($bselected = True) Then $iselected = $lvis_selected
If ($bfocused = True AND $iindex <> -1) Then $ifocused = $lvis_f
ocused
DllStructSetData($tstruct, "Mask", $lvif_state)
DllStructSetData($tstruct, "Item", $iindex)
DllStructSetData($tstruct, "State", BitOR($iselected, $ifocused)
)
DllStructSetData($tstruct, "StateMask", BitOR($lvis_selected, $i
focused))
$isize = DllStructGetSize($tstruct)
If IsHWnd($hwnd) Then
$pmemory = _meminit($hwnd, $isize, $tmemmap)
_memwrite($tmemmap, $tstruct, $pmemory, $isize)
$iret = _sendmessage($hwnd, $lvm_setitemstate, $iindex,
$pmemory)
_memfree($tmemmap)
Else
$iret = GUICtrlSendMsg($hwnd, $lvm_setitemstate, $iindex
, DllStructGetPtr($tstruct))
EndIf
Return $iret <> 0
EndFunc
Func _guictrllistview_setitemstate($hwnd, $iindex, $istate, $istatemask)
Local $titem = DllStructCreate($taglvitem)
DllStructSetData($titem, "Mask", $lvif_state)
DllStructSetData($titem, "Item", $iindex)
DllStructSetData($titem, "State", $istate)
DllStructSetData($titem, "StateMask", $istatemask)
Return _guictrllistview_setitemex($hwnd, $titem) <> 0
EndFunc
Func _guictrllistview_setitemstateimage($hwnd, $iindex, $iimage)
Return _guictrllistview_setitemstate($hwnd, $iindex, BitShift($i
image, -12), $lvis_stateimagemask)
EndFunc
Func _guictrllistview_setitemtext($hwnd, $iindex, $stext, $isubitem = 0)
Local $bunicode = _guictrllistview_getunicodeformat($hwnd)
Local $iret
If $isubitem = -1 Then
EndFunc
lor)
EndIf
Return $iret <> 0
color)
EndFunc
EndIf
ndex)
iindex)
EndFunc
EndIf
r)
lor)
EndFunc
_winapi_invalidaterect($hwnd)
$iret = GUICtrlSendMsg($hwnd, $lvm_settextcolor, 0, $ico
_winapi_invalidaterect(GUICtrlGetHandle($hwnd))
EndIf
Return $iret <> 0
ode)
icode, 0)
EndFunc
EndIf
wnd)
If $iitemcount Then
Local $idescending = 0
If UBound($vsortsense) Then
$idescending = $vsortsense[$icol]
Else
$idescending = $vsortsense
EndIf
Local $vseparatorchar = Opt("GUIDataSeparatorChar")
Local $icolumncount = _guictrllistview_getcolumncount($h
EndIf
ExitLoop
acheckeditems[$j] Then
EndIf
Next
For $j = 1 To $acheckeditems[0]
If $alistviewitems[$i][$iindexvalue] = $
_guictrllistview_setitemchecked(
EndFunc
EndIf
ExitLoop
Next
Next
If $btogglesense Then
If UBound($vsortsense) Then
$vsortsense[$icol] = NOT $idescending
Else
$vsortsense = NOT $idescending
EndIf
EndIf
EndFunc
])
dex][6]
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_hlvlastwnd) Then
_sendmessage($hwnd, $lvm_subitemhittest, 0, $tte
st, 0, "wparam", "struct*")
Else
$itest = DllStructGetSize($ttest)
$pmemory = _meminit($hwnd, $itest, $tmemmap)
_memwrite($tmemmap, $ttest)
_sendmessage($hwnd, $lvm_subitemhittest, 0, $pme
mory, 0, "wparam", "ptr")
_memread($tmemmap, $pmemory, $ttest, $itest)
_memfree($tmemmap)
EndIf
Else
GUICtrlSendMsg($hwnd, $lvm_subitemhittest, 0, DllStructG
etPtr($ttest))
EndIf
$iflags = DllStructGetData($ttest, "Flags")
$atest[0] = DllStructGetData($ttest, "Item")
$atest[1] = DllStructGetData($ttest, "SubItem")
$atest[2] = BitAND($iflags, $lvht_nowhere) <> 0
$atest[3] = BitAND($iflags, $lvht_onitemicon) <> 0
$atest[4] = BitAND($iflags, $lvht_onitemlabel) <> 0
$atest[5] = BitAND($iflags, $lvht_onitemstateicon) <> 0
$atest[6] = BitAND($iflags, $lvht_onitem) <> 0
$atest[7] = BitAND($iflags, $lvht_above) <> 0
$atest[8] = BitAND($iflags, $lvht_below) <> 0
$atest[9] = BitAND($iflags, $lvht_toleft) <> 0
$atest[10] = BitAND($iflags, $lvht_toright) <> 0
Return $atest
EndFunc
Func _guictrllistview_unregistersortcallback($hwnd)
If NOT IsHWnd($hwnd) Then $hwnd = GUICtrlGetHandle($hwnd)
For $x = 1 To $__g_alistviewsortinfo[0][0]
If $hwnd = $__g_alistviewsortinfo[$x][1] Then
DllCallbackFree($__g_alistviewsortinfo[$x][2])
__guictrllistview_arraydelete($__g_alistviewsort
info, $x)
$__g_alistviewsortinfo[0][0] -= 1
ExitLoop
EndIf
Next
EndFunc
Global $__g_htablastwnd
Global Const $__tabconstant_classname = "SysTabControl32"
Global Const $__tabconstant_ws_clipsiblings = 67108864
Global Const $__tabconstant_wm_notify = 78
Global Const $__tabconstant_default_gui_font = 17
Global Const $tagtcitem = "uint Mask;dword State;dword StateMask;ptr Tex
t;int TextMax;int Image;lparam Param"
Global Const $tagtchittestinfo = $tagpoint & ";uint Flags"
Func __guictrltab_adjustrect($hwnd, ByRef $trect, $blarger = False)
If IsHWnd($hwnd) Then
If _winapi_inprocess($hwnd, $__g_htablastwnd) Then
_sendmessage($hwnd, $tcm_adjustrect, $blarger, $
trect, 0, "wparam", "struct*")
Else
p)
pmemory, 0, "wparam", "ptr")
EndFunc
EndIf
EndIf
Return $trect
_memwrite($tmemmap, $trect)
_sendmessage($hwnd, $tcm_adjustrect, $blarger, $
_memread($tmemmap, $pmemory, $trect, $irect)
_memfree($tmemmap)
<> 0
Func _guictrltab_deleteallitems($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $tcm_deleteallitems) <> 0
Else
Return GUICtrlSendMsg($hwnd, $tcm_deleteallitems, 0, 0)
EndFunc
EndIf
) <> 0
EndFunc
EndIf
Else
Else
EndFunc
n $ii
EndIf
EndIf
Return SetError(1, 1, False)
$idestroyed = GUICtrlDelete($hwnd)
EndIf
If $idestroyed Then $hwnd = 0
Return $idestroyed <> 0
EndFunc
EndSwitch
Next
Return -1
Func _guictrltab_getcurfocus($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $tcm_getcurfocus)
Else
Return GUICtrlSendMsg($hwnd, $tcm_getcurfocus, 0, 0)
EndIf
EndFunc
Func _guictrltab_getcursel($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $tcm_getcursel)
Else
Return GUICtrlSendMsg($hwnd, $tcm_getcursel, 0, 0)
EndIf
EndFunc
Func _guictrltab_getdisplayrect($hwnd)
Local $arect[4]
Local $trect = _guictrltab_getdisplayrectex($hwnd)
$arect[0] = DllStructGetData($trect, "Left")
$arect[1] = DllStructGetData($trect, "Top")
$arect[2] = DllStructGetData($trect, "Right")
$arect[3] = DllStructGetData($trect, "Bottom")
Return $arect
EndFunc
Func _guictrltab_getdisplayrectex($hwnd)
Local $trect = _winapi_getclientrect($hwnd)
Return __guictrltab_adjustrect($hwnd, $trect)
EndFunc
Func _guictrltab_getextendedstyle($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $tcm_getextendedstyle)
Else
)
EndFunc
))
EndIf
Func _guictrltab_getimagelist($hwnd)
If IsHWnd($hwnd) Then
Return Ptr(_sendmessage($hwnd, $tcm_getimagelist))
Else
Return Ptr(GUICtrlSendMsg($hwnd, $tcm_getimagelist, 0, 0
EndFunc
EndIf
EndFunc
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $tcm_getitemcount)
Else
Return GUICtrlSendMsg($hwnd, $tcm_getitemcount, 0, 0)
EndIf
Func _guictrltab_getrowcount($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $tcm_getrowcount)
Else
Return GUICtrlSendMsg($hwnd, $tcm_getrowcount, 0, 0)
EndIf
EndFunc
))
Func _guictrltab_gettooltips($hwnd)
If IsHWnd($hwnd) Then
Return HWnd(_sendmessage($hwnd, $tcm_gettooltips))
Else
Return HWnd(GUICtrlSendMsg($hwnd, $tcm_gettooltips, 0, 0
EndFunc
) <> 0
EndIf
Func _guictrltab_getunicodeformat($hwnd)
If IsHWnd($hwnd) Then
Return _sendmessage($hwnd, $tcm_getunicodeformat) <> 0
Else
Return GUICtrlSendMsg($hwnd, $tcm_getunicodeformat, 0, 0
EndFunc
EndIf
EndFunc
m = 0)
")
$tcif_param))
$ibuffer *= 2
$tbuffer = DllStructCreate("char Text[" & $ibuffer & "]"
EndIf
Local $pbuffer = DllStructGetPtr($tbuffer)
Local $titem = DllStructCreate($tagtcitem)
DllStructSetData($tbuffer, "Text", $stext)
DllStructSetData($titem, "Mask", BitOR($tcif_text, $tcif_image,
EndFunc
Return $iret
tyle)
istyle)
EndFunc
EndIf
Else
er & "]")
r))
ibuffer)
mory) <> 0
mory) <> 0
EndFunc
EndIf
DllStructSetData($tbuffer, "Text", $stext)
DllStructSetData($titem, "Text", DllStructGetPtr($tbuffe
$imask = $tcif_text
EndIf
If $istate <> -1 Then
DllStructSetData($titem, "State", $istate)
DllStructSetData($titem, "StateMask", $istate)
$imask = BitOR($imask, $tcif_state)
EndIf
If $iimage <> -1 Then
DllStructSetData($titem, "Image", $iimage)
$imask = BitOR($imask, $tcif_image)
EndIf
If $iparam <> -1 Then
DllStructSetData($titem, "Param", $iparam)
$imask = BitOR($imask, $tcif_param)
EndIf
DllStructSetData($titem, "Mask", $imask)
Local $iitem = DllStructGetSize($titem)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $iitem + 8192, $tmemmap)
Local $ptext = $pmemory + 4096
DllStructSetData($titem, "Text", $ptext)
_memwrite($tmemmap, $titem, $pmemory, $iitem)
If IsString($stext) Then _memwrite($tmemmap, $tbuffer, $ptext, $
If $bunicode Then
$iret = _sendmessage($hwnd, $tcm_setitemw, $iindex, $pme
Else
EndIf
_memfree($tmemmap)
Return $iret
width)
inwidth)
EndIf
EndFunc
hwnd")
EndFunc
EndIf
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$fw_dontcare = 0
$fw_thin = 100
$fw_extralight = 200
$fw_ultralight = 200
$fw_light = 300
$fw_normal = 400
$fw_regular = 400
$fw_medium = 500
$fw_semibold = 600
$fw_demibold = 600
$fw_bold = 700
$fw_extrabold = 800
$fw_ultrabold = 800
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$fw_heavy = 900
$fw_black = 900
$cf_effects = 256
$cf_printerfonts = 2
$cf_screenfonts = 1
$cf_noscriptsel = 8388608
$cf_inittologfontstruct = 64
$logpixelsx = 88
$logpixelsy = 90
$ansi_charset = 0
$arabic_charset = 178
$baltic_charset = 186
$chinesebig5_charset = 136
$default_charset = 1
$easteurope_charset = 238
$gb2312_charset = 134
$greek_charset = 161
$hangeul_charset = 129
$hebrew_charset = 177
$johab_charset = 130
$mac_charset = 77
$oem_charset = 255
$russian_charset = 204
$shiftjis_charset = 128
$symbol_charset = 2
$thai_charset = 222
$turkish_charset = 162
$vietnamese_charset = 163
$out_character_precis = 2
$out_default_precis = 0
$out_device_precis = 5
$out_outline_precis = 8
$out_ps_only_precis = 10
$out_raster_precis = 6
$out_string_precis = 1
$out_stroke_precis = 3
$out_tt_only_precis = 7
$out_tt_precis = 4
$clip_character_precis = 1
$clip_default_precis = 0
$clip_dfa_disable = 48
$clip_embedded = 128
$clip_lh_angles = 16
$clip_mask = 15
$clip_dfa_override = 64
$clip_stroke_precis = 2
$clip_tt_always = 32
$antialiased_quality = 4
$default_quality = 0
$draft_quality = 1
$nonantialiased_quality = 3
$proof_quality = 2
$cleartype_quality = 5
$default_pitch = 0
$fixed_pitch = 1
$variable_pitch = 2
$ff_decorative = 80
$ff_dontcare = 0
$ff_modern = 48
$ff_roman = 16
Else
lLock", "handle", $hglobal)
$ilasterror = _winapi_getlasterror()
Local $hglobal = $aresult[0]
$aresult = DllCall("kernel32.dll", "ptr", "Globa
]) Then
Return SetExtended(2, 1)
ElseIf Number($aversion1[$i]) < Number($aversion
2[$i]) Then
Else
EndIf
EndIf
EndFunc
EndIf
Next
Return SetExtended(Abs($ipartdifference), 0)
Func __misc_getdc($hwnd)
Local $aresult = DllCall("user32.dll", "handle", "GetDC", "hwnd"
, $hwnd)
If @error OR NOT $aresult[0] Then Return SetError(1, _winapi_get
lasterror(), 0)
Return $aresult[0]
EndFunc
Func __misc_getdevicecaps($hdc, $iindex)
Local $aresult = DllCall("gdi32.dll", "int", "GetDeviceCaps", "h
andle", $hdc, "int", $iindex)
If @error Then Return SetError(@error, @extended, 0)
Return $aresult[0]
EndFunc
Func __misc_releasedc($hwnd, $hdc)
Local $aresult = DllCall("user32.dll", "int", "ReleaseDC", "hwnd
", $hwnd, "handle", $hdc)
If @error Then Return SetError(@error, @extended, False)
Return $aresult[0] <> 0
EndFunc
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
EndFunc
Func _guictrlipaddress_getex($hwnd)
Local $tip = DllStructCreate($taggetipaddress)
If @error Then Return SetError(1, 1, "")
If _winapi_inprocess($hwnd, $__g_hiplastwnd) Then
_sendmessage($hwnd, $ipm_getaddress, 0, $tip, 0, "wparam
", "struct*")
Else
Local $iip = DllStructGetSize($tip)
Local $tmemmap
Local $pmemory = _meminit($hwnd, $iip, $tmemmap)
_sendmessage($hwnd, $ipm_getaddress, 0, $pmemory, 0, "wp
aram", "ptr")
_memread($tmemmap, $pmemory, $tip, $iip)
_memfree($tmemmap)
EndIf
Return $tip
EndFunc
Func _guictrlipaddress_isblank($hwnd)
Return _sendmessage($hwnd, $ipm_isblank) <> 0
EndFunc
x])
EndFunc
ss[$x])
EndIf
Next
_guictrlipaddress_setex($hwnd, $tip)
EndFunc
EndIf
Next
_guictrlipaddress_setex($hwnd, $tip)
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$acs_center = 1
$acs_transparent = 2
$acs_autoplay = 4
$acs_timer = 8
$acs_nontransparent = 16
$gui_ss_default_avi = $acs_transparent
$__aviconstant_wm_user = 1024
$acm_opena = $__aviconstant_wm_user + 100
$acm_play = $__aviconstant_wm_user + 101
$acm_stop = $__aviconstant_wm_user + 102
$acm_isplaying = $__aviconstant_wm_user + 104
$acm_openw = $__aviconstant_wm_user + 103
$acn_start = 1
$acn_stop = 2
$dts_shortdateformat = 0
$dts_updown = 1
$dts_shownone = 2
$dts_longdateformat = 4
$dts_timeformat = 9
$dts_rightalign = 32
$dts_shortdatecenturyformat = 12
$dts_appcanparse = 16
$dmw_longname = 0
$dmw_shortname = 1
$dmw_locale_longname = 2
$dmw_locale_shortname = 3
$gdt_error = -1
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$gdt_valid = 0
$gdt_none = 1
$gdtr_min = 1
$gdtr_max = 2
$mcht_nowhere = 0
$mcht_title = 65536
$mcht_calendar = 131072
$mcht_todaylink = 196608
$mcht_next = 16777216
$mcht_prev = 33554432
$mcht_titlebk = 65536
$mcht_titlemonth = 65537
$mcht_titleyear = 65538
$mcht_titlebtnnext = 16842755
$mcht_titlebtnprev = 33619971
$mcht_calendarbk = 131072
$mcht_calendardate = 131073
$mcht_calendarday = 131074
$mcht_calendarweeknum = 131075
$mcht_calendardatenext = 16908288
$mcht_calendardateprev = 33685504
$mcs_daystate = 1
$mcs_multiselect = 2
$mcs_weeknumbers = 4
$mcs_notodaycircle = 8
$mcs_notoday = 16
$mcs_notrailingdates = 64
$mcs_shortdaysofweek = 128
$mcs_noselchangeonnav = 256
$mcm_first = 4096
$mcm_getcalendarborder = ($mcm_first + 31)
$mcm_getcalendarcount = ($mcm_first + 23)
$mcm_getcalendargridinfo = ($mcm_first + 24)
$mcm_getcalid = ($mcm_first + 27)
$mcm_getcolor = ($mcm_first + 11)
$mcm_getcurrentview = ($mcm_first + 22)
$mcm_getcursel = ($mcm_first + 1)
$mcm_getfirstdayofweek = ($mcm_first + 16)
$mcm_getmaxselcount = ($mcm_first + 3)
$mcm_getmaxtodaywidth = ($mcm_first + 21)
$mcm_getminreqrect = ($mcm_first + 9)
$mcm_getmonthdelta = ($mcm_first + 19)
$mcm_getmonthrange = ($mcm_first + 7)
$mcm_getrange = ($mcm_first + 17)
$mcm_getselrange = ($mcm_first + 5)
$mcm_gettoday = ($mcm_first + 13)
$mcm_getunicodeformat = 8192 + 6
$mcm_hittest = ($mcm_first + 14)
$mcm_setcalendarborder = ($mcm_first + 30)
$mcm_setcalid = ($mcm_first + 28)
$mcm_setcolor = ($mcm_first + 10)
$mcm_setcurrentview = ($mcm_first + 32)
$mcm_setcursel = ($mcm_first + 2)
$mcm_setdaystate = ($mcm_first + 8)
$mcm_setfirstdayofweek = ($mcm_first + 15)
$mcm_setmaxselcount = ($mcm_first + 4)
$mcm_setmonthdelta = ($mcm_first + 20)
$mcm_setrange = ($mcm_first + 18)
$mcm_setselrange = ($mcm_first + 6)
$mcm_settoday = ($mcm_first + 12)
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$mcm_setunicodeformat = 8192 + 5
$mcm_sizerecttomin = ($mcm_first + 29)
$mcn_first = -746
$mcn_selchange = ($mcn_first - 3)
$mcn_getdaystate = ($mcn_first - 1)
$mcn_select = ($mcn_first)
$mcn_viewchange = ($mcn_first - 4)
$mcsc_background = 0
$mcsc_monthbk = 4
$mcsc_text = 1
$mcsc_titlebk = 2
$mcsc_titletext = 3
$mcsc_trailingtext = 5
$dtm_first = 4096
$dtm_getsystemtime = $dtm_first + 1
$dtm_setsystemtime = $dtm_first + 2
$dtm_getrange = $dtm_first + 3
$dtm_setrange = $dtm_first + 4
$dtm_setformat = $dtm_first + 5
$dtm_setmccolor = $dtm_first + 6
$dtm_getmccolor = $dtm_first + 7
$dtm_getmonthcal = $dtm_first + 8
$dtm_setmcfont = $dtm_first + 9
$dtm_getmcfont = $dtm_first + 10
$dtm_setformatw = $dtm_first + 50
$dtn_first = -740
$dtn_first2 = -753
$dtn_datetimechange = $dtn_first2 - 6
$dtn_userstring = $dtn_first2 - 5
$dtn_wmkeydown = $dtn_first2 - 4
$dtn_format = $dtn_first2 - 3
$dtn_formatquery = $dtn_first2 - 2
$dtn_dropdown = $dtn_first2 - 1
$dtn_closeup = $dtn_first2 + 0
$dtn_userstringw = $dtn_first - 5
$dtn_wmkeydownw = $dtn_first - 4
$dtn_formatw = $dtn_first - 3
$dtn_formatqueryw = $dtn_first - 2
$gui_ss_default_date = $dts_longdateformat
$gui_ss_default_monthcal = 0
$lbs_notify = 1
$lbs_sort = 2
$lbs_noredraw = 4
$lbs_multiplesel = 8
$lbs_ownerdrawfixed = 16
$lbs_ownerdrawvariable = 32
$lbs_hasstrings = 64
$lbs_usetabstops = 128
$lbs_nointegralheight = 256
$lbs_multicolumn = 512
$lbs_wantkeyboardinput = 1024
$lbs_extendedsel = 2048
$lbs_disablenoscroll = 4096
$lbs_nodata = 8192
$lbs_nosel = 16384
$lbs_combobox = 32768
$lbs_standard = 3
$gui_ss_default_list = 10485763
$lb_err = -1
$lb_errattribute = -3
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$lb_errrequired = -4
$lb_errspace = -2
$lb_addstring = 384
$lb_insertstring = 385
$lb_deletestring = 386
$lb_selitemrangeex = 387
$lb_resetcontent = 388
$lb_setsel = 389
$lb_setcursel = 390
$lb_getsel = 391
$lb_getcursel = 392
$lb_gettext = 393
$lb_gettextlen = 394
$lb_getcount = 395
$lb_selectstring = 396
$lb_dir = 397
$lb_gettopindex = 398
$lb_findstring = 399
$lb_getselcount = 400
$lb_getselitems = 401
$lb_settabstops = 402
$lb_gethorizontalextent = 403
$lb_sethorizontalextent = 404
$lb_setcolumnwidth = 405
$lb_addfile = 406
$lb_settopindex = 407
$lb_getitemrect = 408
$lb_getitemdata = 409
$lb_setitemdata = 410
$lb_selitemrange = 411
$lb_setanchorindex = 412
$lb_getanchorindex = 413
$lb_setcaretindex = 414
$lb_getcaretindex = 415
$lb_setitemheight = 416
$lb_getitemheight = 417
$lb_findstringexact = 418
$lb_setlocale = 421
$lb_getlocale = 422
$lb_setcount = 423
$lb_initstorage = 424
$lb_itemfrompoint = 425
$lb_multipleaddstring = 433
$lb_getlistboxinfo = 434
$lbn_errspace = -2
$lbn_selchange = 1
$lbn_dblclk = 2
$lbn_selcancel = 3
$lbn_setfocus = 4
$lbn_killfocus = 5
$pbs_marquee = 8
$pbs_smooth = 1
$pbs_smoothreverse = 16
$pbs_vertical = 4
$gui_ss_default_progress = 0
$__progressbarconstant_wm_user = 1024
$pbm_deltapos = $__progressbarconstant_wm_user + 3
$pbm_getbarcolor = 1039
$pbm_getbkcolor = 1038
$pbm_getpos = $__progressbarconstant_wm_user + 8
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$pbm_getrange = $__progressbarconstant_wm_user + 7
$pbm_getstate = 1041
$pbm_getstep = 1037
$pbm_setbarcolor = $__progressbarconstant_wm_user + 9
$pbm_setbkcolor = 8192 + 1
$pbm_setmarquee = $__progressbarconstant_wm_user + 10
$pbm_setpos = $__progressbarconstant_wm_user + 2
$pbm_setrange = $__progressbarconstant_wm_user + 1
$pbm_setrange32 = $__progressbarconstant_wm_user + 6
$pbm_setstate = 1040
$pbm_setstep = $__progressbarconstant_wm_user + 4
$pbm_stepit = $__progressbarconstant_wm_user + 5
$__richeditconstant_wm_user = 1024
$em_autourldetect = $__richeditconstant_wm_user + 91
$em_canpaste = $__richeditconstant_wm_user + 50
$em_canredo = $__richeditconstant_wm_user + 85
$em_displayband = $__richeditconstant_wm_user + 51
$em_exgetsel = $__richeditconstant_wm_user + 52
$em_exlimittext = $__richeditconstant_wm_user + 53
$em_exlinefromchar = $__richeditconstant_wm_user + 54
$em_exsetsel = $__richeditconstant_wm_user + 55
$em_findtext = $__richeditconstant_wm_user + 56
$em_findtextex = $__richeditconstant_wm_user + 79
$em_findtextexw = $__richeditconstant_wm_user + 124
$em_findtextw = $__richeditconstant_wm_user + 123
$em_findwordbreak = $__richeditconstant_wm_user + 76
$em_formatrange = $__richeditconstant_wm_user + 57
$em_getautourldetect = $__richeditconstant_wm_user + 92
$em_getbidioptions = $__richeditconstant_wm_user + 201
$em_getcharformat = $__richeditconstant_wm_user + 58
$em_geteditstyle = $__richeditconstant_wm_user + 205
$em_geteventmask = $__richeditconstant_wm_user + 59
$em_getimecolor = $__richeditconstant_wm_user + 105
$em_getimecompmode = $__richeditconstant_wm_user + 122
$em_getimemodebias = $__richeditconstant_wm_user + 127
$em_getimeoptions = $__richeditconstant_wm_user + 107
$em_getlangoptions = $__richeditconstant_wm_user + 121
$em_getoptions = $__richeditconstant_wm_user + 78
$em_getparaformat = $__richeditconstant_wm_user + 61
$em_getpunctuation = $__richeditconstant_wm_user + 101
$em_getredoname = $__richeditconstant_wm_user + 87
$em_getscrollpos = $__richeditconstant_wm_user + 221
$em_getseltext = $__richeditconstant_wm_user + 62
$em_gettextex = $__richeditconstant_wm_user + 94
$em_gettextlengthex = $__richeditconstant_wm_user + 95
$em_gettextmode = $__richeditconstant_wm_user + 90
$em_gettextrange = $__richeditconstant_wm_user + 75
$em_gettypographyoptions = $__richeditconstant_wm_user + 20
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$em_getundoname = $__richeditconstant_wm_user + 86
$em_getwordbreakprocex = $__richeditconstant_wm_user + 80
$em_getwordwrapmode = $__richeditconstant_wm_user + 103
$em_getzoom = $__richeditconstant_wm_user + 224
$em_hideselection = $__richeditconstant_wm_user + 63
$em_pastespecial = $__richeditconstant_wm_user + 64
$em_reconversion = $__richeditconstant_wm_user + 125
$em_redo = $__richeditconstant_wm_user + 84
$em_requestresize = $__richeditconstant_wm_user + 65
$em_selectiontype = $__richeditconstant_wm_user + 66
$em_setbidioptions = $__richeditconstant_wm_user + 200
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$em_setbkgndcolor = $__richeditconstant_wm_user + 67
$em_setcharformat = $__richeditconstant_wm_user + 68
$em_seteditstyle = $__richeditconstant_wm_user + 204
$em_seteventmask = $__richeditconstant_wm_user + 69
$em_setfontsize = $__richeditconstant_wm_user + 223
$em_setimecolor = $__richeditconstant_wm_user + 104
$em_setimemodebias = $__richeditconstant_wm_user + 126
$em_setimeoptions = $__richeditconstant_wm_user + 106
$em_setlangoptions = $__richeditconstant_wm_user + 120
$em_setolecallback = $__richeditconstant_wm_user + 70
$em_setoptions = $__richeditconstant_wm_user + 77
$em_setpalette = $__richeditconstant_wm_user + 93
$em_setparaformat = $__richeditconstant_wm_user + 71
$em_setpunctuation = $__richeditconstant_wm_user + 100
$em_setscrollpos = $__richeditconstant_wm_user + 222
$em_settargetdevice = $__richeditconstant_wm_user + 72
$em_settextex = $__richeditconstant_wm_user + 97
$em_settextmode = $__richeditconstant_wm_user + 89
$em_settypographyoptions = $__richeditconstant_wm_user + 20
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$em_setundolimit = $__richeditconstant_wm_user + 82
$em_setwordbreakprocex = $__richeditconstant_wm_user + 81
$em_setwordwrapmode = $__richeditconstant_wm_user + 102
$em_setzoom = $__richeditconstant_wm_user + 225
$em_showscrollbar = $__richeditconstant_wm_user + 96
$em_stopgrouptyping = $__richeditconstant_wm_user + 88
$em_streamin = $__richeditconstant_wm_user + 73
$em_streamout = $__richeditconstant_wm_user + 74
$en_alignltr = 1808
$en_alignrtl = 1809
$en_correcttext = 1797
$en_dragdropdone = 1804
$en_dropfiles = 1795
$en_imechange = 1799
$en_link = 1803
$en_msgfilter = 1792
$en_objectpositions = 1802
$en_oleopfailed = 1801
$en_protected = 1796
$en_requestresize = 1793
$en_saveclipboard = 1800
$en_selchange = 1794
$en_stopnoundo = 1798
$enm_change = 1
$enm_correcttext = 4194304
$enm_dragdropdone = 16
$enm_dropfiles = 1048576
$enm_imechange = 8388608
$enm_keyevents = 65536
$enm_link = 67108864
$enm_mouseevents = 131072
$enm_objectpositions = 33554432
$enm_protected = 2097152
$enm_requestresize = 262144
$enm_scroll = 4
$enm_scrollevents = 8
$enm_selchange = 524288
$enm_update = 2
$bom_defparadir = 1
$bom_plaintext = 2
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$bom_neutraloverride = 4
$bom_contextreading = 8
$bom_contextalignment = 16
$bom_legacybidiclass = 64
$boe_rtldir = 1
$boe_plaintext = 2
$boe_neutraloverride = 4
$boe_contextreading = 8
$boe_contextalignment = 16
$boe_legacybidiclass = 64
$st_default = 0
$st_keepundo = 1
$st_selection = 2
$gt_default = 0
$gt_selection = 2
$gt_usecrlf = 1
$gtl_close = 4
$gtl_default = 0
$gtl_numbytes = 16
$gtl_numchars = 8
$gtl_precise = 2
$gtl_usecrlf = 1
$cfu_underlinenone = 0
$cfu_underline = 1
$cfu_underlineword = 2
$cfu_underlinedouble = 3
$cfu_underlinedotted = 4
$cp_acp = 0
$cp_unicode = 1200
$cfe_subscript = 65536
$cfe_superscript = 131072
$cfm_allcaps = 128
$cfm_animation = 262144
$cfm_backcolor = 67108864
$cfm_bold = 1
$cfm_charset = 134217728
$cfm_color = 1073741824
$cfm_disabled = 8192
$cfm_emboss = 2048
$cfm_face = 536870912
$cfm_hidden = 256
$cfm_imprint = 4096
$cfm_italic = 2
$cfm_kerning = 1048576
$cfm_lcid = 33554432
$cfm_link = 32
$cfm_offset = 268435456
$cfm_outline = 512
$cfm_protected = 16
$cfm_revauthor = 32768
$cfm_revised = 16384
$cfm_shadow = 1024
$cfm_size = -2147483648
$cfm_smallcaps = 64
$cfm_spacing = 2097152
$cfm_strikeout = 8
$cfm_style = 524288
$cfm_subscript = BitOR($cfe_subscript, $cfe_superscript)
$cfm_superscript = $cfm_subscript
$cfm_underline = 4
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$cfm_underlinetype = 8388608
$cfm_weight = 4194304
$cfe_allcaps = $cfm_allcaps
$cfe_autobackcolor = $cfm_backcolor
$cfe_autocolor = $cfm_color
$cfe_bold = $cfm_bold
$cfe_disabled = $cfm_disabled
$cfe_emboss = $cfm_emboss
$cfe_hidden = $cfm_hidden
$cfe_imprint = $cfm_imprint
$cfe_italic = $cfm_italic
$cfe_link = $cfm_link
$cfe_outline = $cfm_outline
$cfe_protected = $cfm_protected
$cfe_revised = $cfm_revised
$cfe_shadow = $cfm_shadow
$cfe_smallcaps = $cfm_smallcaps
$cfe_strikeout = $cfm_strikeout
$cfe_underline = $cfm_underline
$fr_matchalefhamza = -2147483648
$fr_matchdiac = 536870912
$fr_matchkashida = 1073741824
$scf_default = 0
$scf_selection = 1
$scf_word = 2
$scf_all = 4
$scf_useuirules = 8
$scf_associatefont = 16
$scf_nokbupdate = 32
$lf_facesize = 32
$max_tab_stops = 32
$pfa_left = 1
$pfa_right = 2
$pfa_center = 3
$pfa_justify = 4
$pfa_full_interword = 4
$pfe_table = 16384
$pfm_numbering = 32
$pfm_alignment = 8
$pfm_spacebefore = 64
$pfm_numberingstyle = 8192
$pfm_numberingstart = 32768
$pfm_border = 2048
$pfm_rightindent = 2
$pfm_startindent = 1
$pfm_offset = 4
$pfm_linespacing = 256
$pfm_spaceafter = 128
$pfm_numberingtab = 16384
$pfm_table = 1073741824
$pfm_tabstops = 16
$pfn_bullet = 1
$pfm_rtlpara = 65536
$pfm_keep = 131072
$pfm_keepnext = 262144
$pfm_pagebreakbefore = 524288
$pfm_nolinenumber = 1048576
$pfm_nowidowcontrol = 2097152
$pfm_donothyphen = 4194304
$pfm_sidebyside = 8388608
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$pfe_rtlpara = 1
$pfe_keep = 2
$pfe_keepnext = 4
$pfe_pagebreakbefore = 8
$pfe_nolinenumber = 16
$pfe_nowidowcontrol = 32
$pfe_donothyphen = 64
$pfe_sidebyside = 128
$pfm_shading = 4096
$wb_classify = 3
$wb_isdelimiter = 2
$wb_left = 0
$wb_leftbreak = 6
$wb_movewordleft = 4
$wb_movewordnext = 5
$wb_movewordprev = 4
$wb_movewordright = 5
$wb_nextbreak = 7
$wb_prevbreak = 6
$wb_right = 1
$wb_rightbreak = 7
$wbf_iswhite = 16
$wbf_breakline = 32
$wbf_breakafter = 64
$sf_text = 1
$sf_rtf = 2
$sf_rtfnoobjs = 3
$sf_textized = 4
$sf_unicode = 16
$sf_usecodepage = 32
$sff_plainrtf = 16384
$sff_selection = 32768
$tbcd_channel = 3
$tbcd_thumb = 2
$tbcd_tics = 1
$__sliderconstant_wm_user = 1024
$tbm_clearsel = $__sliderconstant_wm_user + 19
$tbm_cleartics = $__sliderconstant_wm_user + 9
$tbm_getbuddy = $__sliderconstant_wm_user + 33
$tbm_getchannelrect = $__sliderconstant_wm_user + 26
$tbm_getlinesize = $__sliderconstant_wm_user + 24
$tbm_getnumtics = $__sliderconstant_wm_user + 16
$tbm_getpagesize = $__sliderconstant_wm_user + 22
$tbm_getpos = $__sliderconstant_wm_user
$tbm_getptics = $__sliderconstant_wm_user + 14
$tbm_getselend = $__sliderconstant_wm_user + 18
$tbm_getselstart = $__sliderconstant_wm_user + 17
$tbm_getrangemax = $__sliderconstant_wm_user + 2
$tbm_getrangemin = $__sliderconstant_wm_user + 1
$tbm_getthumblength = $__sliderconstant_wm_user + 28
$tbm_getthumbrect = $__sliderconstant_wm_user + 25
$tbm_gettic = $__sliderconstant_wm_user + 3
$tbm_getticpos = $__sliderconstant_wm_user + 15
$tbm_gettooltips = $__sliderconstant_wm_user + 30
$tbm_getunicodeformat = 8192 + 6
$tbm_setbuddy = $__sliderconstant_wm_user + 32
$tbm_setlinesize = $__sliderconstant_wm_user + 23
$tbm_setpagesize = $__sliderconstant_wm_user + 21
$tbm_setpos = $__sliderconstant_wm_user + 5
$tbm_setrange = $__sliderconstant_wm_user + 6
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$tvgn_firstvisible = 5
$tvgn_nextvisible = 6
$tvgn_previousvisible = 7
$tvgn_drophilite = 8
$tvgn_caret = 9
$tvgn_lastvisible = 10
$tvht_nowhere = 1
$tvht_onitemicon = 2
$tvht_onitemlabel = 4
$tvht_onitemindent = 8
$tvht_onitembutton = 16
$tvht_onitemright = 32
$tvht_onitemstateicon = 64
$tvht_onitem = 70
$tvht_above = 256
$tvht_below = 512
$tvht_toright = 1024
$tvht_toleft = 2048
$tvi_root = -65536
$tvi_first = -65535
$tvi_last = -65534
$tvi_sort = -65533
$tvif_text = 1
$tvif_image = 2
$tvif_param = 4
$tvif_state = 8
$tvif_handle = 16
$tvif_selectedimage = 32
$tvif_children = 64
$tvif_integral = 128
$tvif_expandedimage = 256
$tvif_stateex = 512
$tvif_di_setitem = 4096
$tvsil_normal = 0
$tvsil_state = 2
$tvc_bykeyboard = 2
$tvc_bymouse = 1
$tvc_unknown = 0
$tvis_focused = 1
$tvis_selected = 2
$tvis_cut = 4
$tvis_drophilited = 8
$tvis_bold = 16
$tvis_expanded = 32
$tvis_expandedonce = 64
$tvis_expandpartial = 128
$tvis_overlaymask = 3840
$tvis_stateimagemask = 61440
$tvis_usermask = 61440
$tvis_unchecked = 4096
$tvis_checked = 8192
$tvna_add = 1
$tvna_addfirst = 2
$tvna_addchild = 3
$tvna_addchildfirst = 4
$tvna_insert = 5
$tvta_addfirst = 1
$tvta_add = 2
$tvta_insert = 3
$tv_first = 4352
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$tvm_insertitema = $tv_first + 0
$tvm_deleteitem = $tv_first + 1
$tvm_expand = $tv_first + 2
$tvm_getitemrect = $tv_first + 4
$tvm_getcount = $tv_first + 5
$tvm_getindent = $tv_first + 6
$tvm_setindent = $tv_first + 7
$tvm_getimagelist = $tv_first + 8
$tvm_setimagelist = $tv_first + 9
$tvm_getnextitem = $tv_first + 10
$tvm_selectitem = $tv_first + 11
$tvm_getitema = $tv_first + 12
$tvm_setitema = $tv_first + 13
$tvm_editlabela = $tv_first + 14
$tvm_geteditcontrol = $tv_first + 15
$tvm_getvisiblecount = $tv_first + 16
$tvm_hittest = $tv_first + 17
$tvm_createdragimage = $tv_first + 18
$tvm_sortchildren = $tv_first + 19
$tvm_ensurevisible = $tv_first + 20
$tvm_sortchildrencb = $tv_first + 21
$tvm_endeditlabelnow = $tv_first + 22
$tvm_getisearchstringa = $tv_first + 23
$tvm_settooltips = $tv_first + 24
$tvm_gettooltips = $tv_first + 25
$tvm_setinsertmark = $tv_first + 26
$tvm_setitemheight = $tv_first + 27
$tvm_getitemheight = $tv_first + 28
$tvm_setbkcolor = $tv_first + 29
$tvm_settextcolor = $tv_first + 30
$tvm_getbkcolor = $tv_first + 31
$tvm_gettextcolor = $tv_first + 32
$tvm_setscrolltime = $tv_first + 33
$tvm_getscrolltime = $tv_first + 34
$tvm_setinsertmarkcolor = $tv_first + 37
$tvm_getinsertmarkcolor = $tv_first + 38
$tvm_getitemstate = $tv_first + 39
$tvm_setlinecolor = $tv_first + 40
$tvm_getlinecolor = $tv_first + 41
$tvm_mapaccidtohtreeitem = $tv_first + 42
$tvm_maphtreeitemtoaccid = $tv_first + 43
$tvm_insertitemw = $tv_first + 50
$tvm_getitemw = $tv_first + 62
$tvm_setitemw = $tv_first + 63
$tvm_getisearchstringw = $tv_first + 64
$tvm_editlabelw = $tv_first + 65
$tvm_getunicodeformat = 8192 + 6
$tvm_setunicodeformat = 8192 + 5
$tvn_first = -400
$tvn_selchanginga = $tvn_first - 1
$tvn_selchangeda = $tvn_first - 2
$tvn_getdispinfoa = $tvn_first - 3
$tvn_setdispinfoa = $tvn_first - 4
$tvn_itemexpandinga = $tvn_first - 5
$tvn_itemexpandeda = $tvn_first - 6
$tvn_begindraga = $tvn_first - 7
$tvn_beginrdraga = $tvn_first - 8
$tvn_deleteitema = $tvn_first - 9
$tvn_beginlabeledita = $tvn_first - 10
$tvn_endlabeledita = $tvn_first - 11
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$tvn_keydown = $tvn_first - 12
$tvn_getinfotipa = $tvn_first - 13
$tvn_getinfotipw = $tvn_first - 14
$tvn_singleexpand = $tvn_first - 15
$tvn_itemchanginga = $tvn_first - 16
$tvn_itemchangingw = $tvn_first - 17
$tvn_itemchangeda = $tvn_first - 18
$tvn_itemchangedw = $tvn_first - 19
$tvn_selchangingw = $tvn_first - 50
$tvn_selchangedw = $tvn_first - 51
$tvn_getdispinfow = $tvn_first - 52
$tvn_setdispinfow = $tvn_first - 53
$tvn_itemexpandingw = $tvn_first - 54
$tvn_itemexpandedw = $tvn_first - 55
$tvn_begindragw = $tvn_first - 56
$tvn_beginrdragw = $tvn_first - 57
$tvn_deleteitemw = $tvn_first - 58
$tvn_beginlabeleditw = $tvn_first - 59
$tvn_endlabeleditw = $tvn_first - 60
$uds_wrap = 1
$uds_setbuddyint = 2
$uds_alignright = 4
$uds_alignleft = 8
$uds_arrowkeys = 32
$uds_horz = 64
$uds_nothousands = 128
$gui_ss_default_updown = $uds_alignleft
Func _processgetname($ipid)
Local $aprocesslist = ProcessList()
If NOT @error Then
For $i = 1 To $aprocesslist[0][0]
If $aprocesslist[$i][1] = $ipid Then
Return $aprocesslist[$i][0]
EndIf
Next
EndIf
Return SetError(1, 0, "")
EndFunc
Func _processgetpriority($vprocess)
Local $ierror = 0, $iextended = 0, $ireturn = -1
Local $ipid = ProcessExists($vprocess)
If NOT $ipid Then Return SetError(1, 0, -1)
Local $hdll = DllOpen("kernel32.dll")
Do
Local $aprocesshandle = DllCall($hdll, "handle", "OpenPr
ocess", "dword", $process_query_information, "bool", False, "dword", $ipid)
If @error Then
$ierror = @error + 10
$iextended = @extended
ExitLoop
EndIf
If NOT $aprocesshandle[0] Then ExitLoop
Local $apriority = DllCall($hdll, "dword", "GetPriorityC
lass", "handle", $aprocesshandle[0])
If @error Then
$ierror = @error
$iextended = @extended
EndIf
shandle[0])
EndFunc
HIDE)
Func _rundos($scommand)
Local $nresult = RunWait(@ComSpec & " /C " & $scommand, "", @SW_
Return SetError(@error, @extended, $nresult)
EndFunc
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$ddl_archive = 32
$ddl_directory = 16
$ddl_drives = 16384
$ddl_exclusive = 32768
$ddl_hidden = 2
$ddl_readonly = 1
$ddl_readwrite = 0
$ddl_system = 4
$tray_item_exit = 3
$tray_item_pause = 4
$tray_item_first = 7
$tray_checked = 1
$tray_unchecked = 4
$tray_enable = 64
$tray_disable = 128
$tray_focus = 256
$tray_default = 512
$tray_event_none = 0
$tray_event_showicon = -3
$tray_event_hideicon = -4
$tray_event_flashicon = -5
$tray_event_noflashicon = -6
$tray_event_primarydown = -7
$tray_event_primaryup = -8
$tray_event_secondarydown = -9
$tray_event_secondaryup = -10
$tray_event_mouseover = -11
$tray_event_mouseout = -12
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$ts_min = 0
$ts_true = 1
$ts_draw = 2
$po_class = 2
$po_global = 3
$po_notfound = 4
$po_part = 1
$po_state = 0
$tmt_bool = 203
$tmt_color = 204
$tmt_dibdata = 2
$tmt_diskstream = 213
$tmt_enum = 200
$tmt_filename = 206
$tmt_font = 210
$tmt_glyphdibdata = 8
$tmt_hbitmap = 212
$tmt_int = 202
$tmt_intlist = 211
$tmt_margins = 205
$tmt_position = 208
$tmt_rect = 209
$tmt_size = 207
$tmt_string = 201
$tmt_alwaysshowsizingbar = 2208
$tmt_autosize = 2202
$tmt_bgfill = 2205
$tmt_borderonly = 2203
$tmt_composited = 2204
$tmt_compositedopaque = 2219
$tmt_drawborders = 2214
$tmt_flatmenus = 1001
$tmt_glyphonly = 2207
$tmt_glyphtransparent = 2206
$tmt_integralsizing = 2211
$tmt_localizedmirrorimage = 2220
$tmt_mirrorimage = 2209
$tmt_noetchedeffect = 2215
$tmt_sourcegrow = 2212
$tmt_sourceshrink = 2213
$tmt_textapplyoverlay = 2216
$tmt_textglow = 2217
$tmt_textitalic = 2218
$tmt_transparent = 2201
$tmt_uniformsizing = 2210
$tmt_userpicture = 5001
$tmt_accentcolorhint = 3823
$tmt_activeborder = 1611
$tmt_activecaption = 1603
$tmt_appworkspace = 1613
$tmt_background = 1602
$tmt_blendcolor = 5003
$tmt_bodytextcolor = 3827
$tmt_bordercolor = 3801
$tmt_bordercolorhint = 3822
$tmt_btnface = 1616
$tmt_btnhighlight = 1621
$tmt_btnshadow = 1617
$tmt_btntext = 1619
$tmt_buttonalternateface = 1626
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$tmt_captiontext = 1610
$tmt_dkshadow3d = 1622
$tmt_edgedkshadowcolor = 3807
$tmt_edgefillcolor = 3808
$tmt_edgehighlightcolor = 3805
$tmt_edgelightcolor = 3804
$tmt_edgeshadowcolor = 3806
$tmt_fillcolor = 3802
$tmt_fillcolorhint = 3821
$tmt_fromcolor1 = 2001
$tmt_fromcolor2 = 2002
$tmt_fromcolor3 = 2003
$tmt_fromcolor4 = 2004
$tmt_fromcolor5 = 2005
$tmt_glowcolor = 3816
$tmt_glyphtextcolor = 3819
$tmt_glyphtransparentcolor = 3820
$tmt_gradientactivecaption = 1628
$tmt_gradientcolor1 = 3810
$tmt_gradientcolor2 = 3811
$tmt_gradientcolor3 = 3812
$tmt_gradientcolor4 = 3813
$tmt_gradientcolor5 = 3814
$tmt_gradientinactivecaption = 1629
$tmt_graytext = 1618
$tmt_heading1textcolor = 3825
$tmt_heading2textcolor = 3826
$tmt_highlight = 1614
$tmt_highlighttext = 1615
$tmt_hottracking = 1627
$tmt_inactiveborder = 1612
$tmt_inactivecaption = 1604
$tmt_inactivecaptiontext = 1620
$tmt_infobk = 1625
$tmt_infotext = 1624
$tmt_light3d = 1623
$tmt_menu = 1605
$tmt_menubar = 1631
$tmt_menuhilight = 1630
$tmt_menutext = 1608
$tmt_scrollbar = 1601
$tmt_shadowcolor = 3815
$tmt_textbordercolor = 3817
$tmt_textcolor = 3803
$tmt_textcolorhint = 3824
$tmt_textshadowcolor = 3818
$tmt_transparentcolor = 3809
$tmt_window = 1606
$tmt_windowframe = 1607
$tmt_windowtext = 1609
$tmt_atlasimage = 8000
$tmt_bgtype = 4001
$tmt_bordertype = 4002
$tmt_contentalignment = 4006
$tmt_filltype = 4003
$tmt_glyphtype = 4012
$tmt_glyphfontsizingtype = 4014
$tmt_halign = 4005
$tmt_iconeffect = 4009
$tmt_imagelayout = 4011
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$tmt_imageselecttype = 4013
$tmt_offsettype = 4008
$tmt_sizingtype = 4004
$tmt_textshadowtype = 4010
$tmt_truesizescalingtype = 4015
$tmt_valign = 4007
$tmt_glyphimagefile = 3008
$tmt_imagefile = 3001
$tmt_imagefile1 = 3002
$tmt_imagefile2 = 3003
$tmt_imagefile3 = 3004
$tmt_imagefile4 = 3005
$tmt_imagefile5 = 3006
$tmt_scaledbackground = 7001
$tmt_bodyfont = 809
$tmt_captionfont = 801
$tmt_glyphfont = 2601
$tmt_heading1font = 807
$tmt_heading2font = 808
$tmt_icontitlefont = 806
$tmt_menufont = 803
$tmt_msgboxfont = 805
$tmt_smallcaptionfont = 802
$tmt_statusfont = 804
$tmt_alphalevel = 2402
$tmt_alphathreshold = 2415
$tmt_animationdelay = 2428
$tmt_animationduration = 5006
$tmt_bordersize = 2403
$tmt_charset = 403
$tmt_colorizationcolor = 2431
$tmt_colorizationopacity = 2432
$tmt_framespersecond = 2426
$tmt_fromhue1 = 1801
$tmt_fromhue2 = 1802
$tmt_fromhue3 = 1803
$tmt_fromhue4 = 1804
$tmt_fromhue5 = 1805
$tmt_glowintensity = 2429
$tmt_glyphindex = 2418
$tmt_gradientratio1 = 2406
$tmt_gradientratio2 = 2407
$tmt_gradientratio3 = 2408
$tmt_gradientratio4 = 2409
$tmt_gradientratio5 = 2410
$tmt_height = 2417
$tmt_imagecount = 2401
$tmt_mincolordepth = 1301
$tmt_mindpi1 = 2420
$tmt_mindpi2 = 2421
$tmt_mindpi3 = 2422
$tmt_mindpi4 = 2423
$tmt_mindpi5 = 2424
$tmt_opacity = 2430
$tmt_pixelsperframe = 2427
$tmt_progresschunksize = 2411
$tmt_progressspacesize = 2412
$tmt_roundcornerheight = 2405
$tmt_roundcornerwidth = 2404
$tmt_saturation = 2413
EndFunc
de)
Func _winapi_fatalexit($icode)
DllCall("kernel32.dll", "none", "FatalExit", "int", $ico
EndFunc
Func _winapi_getbitmapdimension($hbitmap)
Local Const $tagbitmap = "struct;long bmType;long bmWidt
h;long bmHeight;long bmWidthBytes;ushort bmPlanes;ushort bmBitsPixel;ptr bmBits;
endstruct"
Local $tobj = DllStructCreate($tagbitmap)
Local $aret = DllCall("gdi32.dll", "int", "GetObject", "
handle", $hbitmap, "int", DllStructGetSize($tobj), "struct*", $tobj)
If @error OR NOT $aret[0] Then Return SetError(@error +
10, @extended, 0)
Return _winapi_createsize(DllStructGetData($tobj, "bmWid
th"), DllStructGetData($tobj, "bmHeight"))
EndFunc
Func _winapi_getstring($pstring, $bunicode = True)
Local $ilength = _winapi_strlen($pstring, $bunicode)
If @error OR NOT $ilength Then Return SetError(@error +
10, @extended, "")
Local $tstring = DllStructCreate(__iif($bunicode, "wchar
", "char") & "[" & ($ilength + 1) & "]", $pstring)
If @error Then Return SetError(@error, @extended, "")
Return SetExtended($ilength, DllStructGetData($tstring,
1))
EndFunc
Func _winapi_isbadreadptr($paddress, $ilength)
Local $aret = DllCall("kernel32.dll", "bool", "IsBadRead
Ptr", "struct*", $paddress, "uint_ptr", $ilength)
If @error Then Return SetError(@error, @extended, False)
Return $aret[0]
EndFunc
Func _winapi_isbadwriteptr($paddress, $ilength)
Local $aret = DllCall("kernel32.dll", "bool", "IsBadWrit
ePtr", "struct*", $paddress, "uint_ptr", $ilength)
If @error Then Return SetError(@error, @extended, False)
Return $aret[0]
EndFunc
Func _winapi_iswow64process($ipid = 0)
If NOT $ipid Then $ipid = @AutoItPID
Local $hprocess = DllCall("kernel32.dll", "handle", "Ope
nProcess", "dword", __iif($__winver < 1536, 1024, 4096), "bool", 0, "dword", $ip
id)
0)
eturn SetError(3, 0, 0)
EndIf
$ioffset += 2 * (1 + $ilength)
If $ioffset >= $isize Then Return SetError(3, 0,
0)
EndFunc
WEnd
If NOT $aresult[0] Then Return SetError(2, 0, 0)
__inc($aresult, -1)
Return $aresult
Func _winapi_swapdword($ivalue)
Local $tstruct1 = DllStructCreate("dword;dword")
Local $tstruct2 = DllStructCreate("byte[4];byte[4]", Dll
StructGetPtr($tstruct1))
DllStructSetData($tstruct1, 1, $ivalue)
For $i = 1 To 4
DllStructSetData($tstruct2, 2, DllStructGetData(
$tstruct2, 1, 5 - $i), $i)
Next
Return DllStructGetData($tstruct1, 2)
EndFunc
Func _winapi_swapqword($ivalue)
Local $tstruct1 = DllStructCreate("int64;int64")
Local $tstruct2 = DllStructCreate("byte[8];byte[8]", Dll
StructGetPtr($tstruct1))
DllStructSetData($tstruct1, 1, $ivalue)
For $i = 1 To 8
DllStructSetData($tstruct2, 2, DllStructGetData(
$tstruct2, 1, 9 - $i), $i)
Next
Return DllStructGetData($tstruct1, 2)
EndFunc
Func _winapi_swapword($ivalue)
Local $tstruct1 = DllStructCreate("word;word")
Local $tstruct2 = DllStructCreate("byte[2];byte[2]", Dll
StructGetPtr($tstruct1))
DllStructSetData($tstruct1, 1, $ivalue)
For $i = 1 To 2
DllStructSetData($tstruct2, 2, DllStructGetData(
$tstruct2, 1, 3 - $i), $i)
Next
Return DllStructGetData($tstruct1, 2)
EndFunc
Func _winapi_switchcolor($icolor)
If $icolor = -1 Then Return $icolor
Return BitOR(BitAND($icolor, 65280), BitShift(BitAND($ic
olor, 255), -16), BitShift(BitAND($icolor, 16711680), 16))
EndFunc
Func _winapi_zeromemory($pmemory, $ilength)
If _winapi_isbadwriteptr($pmemory, $ilength) Then Return
SetError(11, @extended, 0)
DllCall("ntdll.dll", "none", "RtlZeroMemory", "struct*",
$pmemory, "ulong_ptr", $ilength)
If @error Then Return SetError(@error, @extended, 0)
Return 1
EndFunc
Func __rgb($icolor)
If $__g_irgbmode Then
$icolor = _winapi_switchcolor($icolor)
EndIf
Return $icolor
EndFunc
Func __winver()
Local $tosvi = DllStructCreate($tagosversioninfo)
DllStructSetData($tosvi, 1, DllStructGetSize($tosvi))
Local $aret = DllCall("kernel32.dll", "bool", "GetVersio
nExW", "struct*", $tosvi)
If @error OR NOT $aret[0] Then Return SetError(@error, @
extended, 0)
Return BitOR(BitShift(DllStructGetData($tosvi, 2), -8),
DllStructGetData($tosvi, 3))
EndFunc
#EndRegion Internal Functions
#Region Global Variables and Constants
Global Const $tagdttopts = "dword Size;dword Flags;dword clrText
;dword clrBorder;dword clrShadow;int TextShadowType;" & $tagpoint & ";int Border
Size;int FontPropId;int ColorPropId;int StateId;int ApplyOverlay;int GlowSize;pt
r DrawTextCallback;lparam lParam"
#EndRegion Global Variables and Constants
#Region Functions list
#EndRegion Functions list
#Region Public Functions
Func _winapi_beginbufferedpaint($hdc, $ttarget, ByRef $hnewdc, $
iformat = 0, $iflags = 0, $texclude = 0, $ialpha = -1)
Local Const $tagbp_paintparams = "dword cbSize;dword dwF
lags;ptr prcExclude;ptr pBlendFunction"
Local $tpp = DllStructCreate($tagbp_paintparams)
$hnewdc = 0
Local $tbf = 0
If $ialpha <> -1 Then
$tbf = DllStructCreate($tagblendfunction)
DllStructSetData($tbf, 1, 0)
DllStructSetData($tbf, 2, 0)
DllStructSetData($tbf, 3, $ialpha)
DllStructSetData($tbf, 4, 1)
EndIf
DllStructSetData($tpp, 1, DllStructGetSize($tpp))
DllStructSetData($tpp, 2, $iflags)
DllStructSetData($tpp, 3, DllStructGetPtr($texclude))
DllStructSetData($tpp, 4, DllStructGetPtr($tbf))
Local $aret = DllCall("uxtheme.dll", "handle", "BeginBuf
feredPaint", "handle", $hdc, "struct*", $ttarget, "dword", $iformat, "struct*",
$tpp, "handle*", 0)
If @error OR NOT $aret[0] Then Return SetError(@error, @
extended, 0)
$hnewdc = $aret[5]
Return $aret[0]
EndFunc
Func _winapi_bufferedpaintclear($hbp, $trect = 0)
Local $aret = DllCall("uxtheme.dll", "long", "BufferedPa
intClear", "handle", $hbp, "struct*", $trect)
If @error Then Return SetError(@error, @extended, 0)
EndFunc
intInit")
Func _winapi_bufferedpaintinit()
Local $aret = DllCall("uxtheme.dll", "long", "BufferedPa
EndFunc
0)
intUnInit")
Func _winapi_bufferedpaintuninit()
Local $aret = DllCall("uxtheme.dll", "long", "BufferedPa
EndFunc
Func _winapi_closethemedata($htheme)
Local $aret = DllCall("uxtheme.dll", "long", "CloseTheme
Data", "handle", $htheme)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_drawthemebackground($htheme, $ipartid, $istateid, $
hdc, $trect, $tclip = 0)
Local $aret = DllCall("uxtheme.dll", "long", "DrawThemeB
ackground", "handle", $htheme, "handle", $hdc, "int", $ipartid, "int", $istateid
, "struct*", $trect, "struct*", $tclip)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_drawthemeedge($htheme, $ipartid, $istateid, $hdc, $
trect, $iedge, $iflags, $tarea = 0)
Local $aret = DllCall("uxtheme.dll", "long", "DrawThemeE
dge", "handle", $htheme, "handle", $hdc, "int", $ipartid, "int", $istateid, "str
uct*", $trect, "uint", $iedge, "uint", $iflags, "struct*", $tarea)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_drawthemeicon($htheme, $ipartid, $istateid, $hdc, $
trect, $hil, $iindex)
Local $aret = DllCall("uxtheme.dll", "long", "DrawThemeI
con", "handle", $htheme, "handle", $hdc, "int", $ipartid, "int", $istateid, "str
uct*", $trect, "handle", $hil, "int", $iindex)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_drawthemeparentbackground($hwnd, $hdc, $trect = 0)
Local $aret = DllCall("uxtheme.dll", "long", "DrawThemeP
arentBackground", "hwnd", $hwnd, "handle", $hdc, "struct*", $trect)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_drawthemetext($htheme, $ipartid, $istateid, $hdc, $
stext, $trect, $iflags)
Local $aret = DllCall("uxtheme.dll", "long", "DrawThemeT
ext", "handle", $htheme, "handle", $hdc, "int", $ipartid, "int", $istateid, "wst
r", $stext, "int", -1, "dword", $iflags, "dword", 0, "struct*", $trect)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_drawthemetextex($htheme, $ipartid, $istateid, $hdc,
$stext, $trect, $iflags, $tdttopts)
Local $aret = DllCall("uxtheme.dll", "long", "DrawThemeT
extEx", "handle", $htheme, "handle", $hdc, "int", $ipartid, "int", $istateid, "w
str", $stext, "int", -1, "dword", $iflags, "struct*", $trect, "struct*", $tdttop
ts)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_endbufferedpaint($hbp, $bupdate = True)
Local $aret = DllCall("uxtheme.dll", "long", "EndBuffere
dPaint", "handle", $hbp, "bool", $bupdate)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
Func _winapi_getbufferedpaintbits($hbp)
Local $aret = DllCall("uxtheme.dll", "long", "GetBuffere
dPaintBits", "handle", $hbp, "ptr*", 0, "int*", 0)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return SetExtended($aret[3], $aret[2])
EndFunc
Func _winapi_getbufferedpaintdc($hbp)
Local $aret = DllCall("uxtheme.dll", "handle", "GetBuffe
redPaintDC", "handle", $hbp)
If @error Then Return SetError(@error, @extended, 0)
Return $aret[0]
EndFunc
Func _winapi_getbufferedpainttargetdc($hbp)
ppProperties")
Func _winapi_getthemeappproperties()
Local $aret = DllCall("uxtheme.dll", "dword", "GetThemeA
EndFunc
opid)
EndFunc
Func _winapi_getthemesysfont($htheme, $ifontid)
Local $tlogfont = DllStructCreate($taglogfont)
Local $aret = DllCall("uxtheme.dll", "long", "GetThemeSy
sFont", "handle", $htheme, "int", $ifontid, "struct*", $tlogfont)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return $tlogfont
EndFunc
Func _winapi_getthemesysint($htheme, $iintid)
Local $aret = DllCall("uxtheme.dll", "long", "GetThemeSy
sInt", "handle", $htheme, "int", $iintid, "int*", 0)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return $aret[3]
EndFunc
Func _winapi_getthemesyssize($htheme, $isizeid)
Local $aret = DllCall("uxtheme.dll", "int", "GetThemeSys
Size", "handle", $htheme, "int", $isizeid)
If @error Then Return SetError(@error, @extended, 0)
Return $aret[0]
EndFunc
Func _winapi_getthemesysstring($htheme, $istringid)
Local $aret = DllCall("uxtheme.dll", "long", "GetThemeSy
sString", "handle", $htheme, "int", $istringid, "wstr", "", "int", 4096)
If @error Then Return SetError(@error, @extended, "")
If $aret[0] Then Return SetError(10, $aret[0], "")
Return $aret[3]
EndFunc
Func _winapi_getthemetextextent($htheme, $ipartid, $istateid, $h
dc, $stext, $trect, $iflags)
Local $tarea = DllStructCreate($tagrect)
Local $aret = DllCall("uxtheme.dll", "long", "GetThemeTe
xtExtent", "handle", $htheme, "handle", $hdc, "int", $ipartid, "int", $istateid,
"wstr", $stext, "int", -1, "dword", $iflags, "struct*", $trect, "struct*", $tar
ea)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return $tarea
EndFunc
hdc = 0)
ive")
Func _winapi_isthemeactive()
Local $aret = DllCall("uxtheme.dll", "bool", "IsThemeAct
EndFunc
EndIf
Local $aret = DllCall("uxtheme.dll", "long", "SetWindowT
heme", "hwnd", $hwnd, $stypeofname, $sname, $stypeoflist, $slist)
If @error Then Return SetError(@error, @extended, 0)
If $aret[0] Then Return SetError(10, $aret[0], 0)
Return 1
EndFunc
#EndRegion Public Functions
Func _hextostring($shex)
If NOT (StringLeft($shex, 2) == "0x") Then $shex = "0x" & $shex
Return BinaryToString($shex, $sb_utf8)
EndFunc
Func _stringbetween($sstring, $sstart, $send, $imode = $str_endisstart,
$bcase = False)
$sstart = $sstart ? "\Q" & $sstart & "\E" : "\A"
If $imode <> $str_endnotstart Then $imode = $str_endisstart
If $imode = $str_endisstart Then
$send = $send ? "(?=\Q" & $send & "\E)" : "\z"
Else
$send = $send ? "\Q" & $send & "\E" : "\z"
EndIf
If $bcase = Default Then
$bcase = False
EndIf
Local $areturn = StringRegExp($sstring, "(?s" & (NOT $bcase ? "i
" : "") & ")" & $sstart & "(.*?)" & $send, $str_regexparrayglobalmatch)
If @error Then Return SetError(1, 0, 0)
Return $areturn
EndFunc
ilimit)
limit)
r_nocount)
EndFunc
$sdelimiter = $null
ElseIf $ilimit < 0 Then
Local $iindex = StringInStr($sstring, $sdelimiter, 0, $i
If $iindex Then
$sstring = StringLeft($sstring, $iindex - 1)
EndIf
EndIf
Return StringSplit($sstring, $sdelimiter, $str_entiresplit + $st
Func _stringproper($sstring)
Local $bcapnext = True, $schr = "", $sreturn = ""
For $i = 1 To StringLen($sstring)
$schr = StringMid($sstring, $i, 1)
Select
Case $bcapnext = True
If StringRegExp($schr, "[a-zA-Z - ]") Then
$schr = StringUpper($schr)
$bcapnext = False
EndIf
Case NOT StringRegExp($schr, "[a-zA-Z - ]")
$bcapnext = True
Case Else
$schr = StringLower($schr)
EndSelect
$sreturn &= $schr
Next
Return $sreturn
EndFunc
Func _stringrepeat($sstring, $irepeatcount)
$irepeatcount = Int($irepeatcount)
If $irepeatcount = 0 Then Return ""
If StringLen($sstring) < 1 OR $irepeatcount < 0 Then Return SetE
rror(1, 0, "")
Local $sresult = ""
While $irepeatcount > 1
If BitAND($irepeatcount, 1) Then $sresult &= $sstring
$sstring &= $sstring
$irepeatcount = BitShift($irepeatcount, 1)
WEnd
Return $sstring & $sresult
EndFunc
Func _stringtitlecase($sstring)
Local $bcapnext = True, $schr = "", $sreturn = ""
For $i = 1 To StringLen($sstring)
$schr = StringMid($sstring, $i, 1)
Select
Case $bcapnext = True
If StringRegExp($schr, "[a-zA-Z\xC0-\xFF
0-9]") Then
$schr = StringUpper($schr)
$bcapnext = False
EndIf
Case NOT StringRegExp($schr, "[a-zA-Z\xC0-\xFF'0
-9]")
$bcapnext = True
Case Else
$schr = StringLower($schr)
EndSelect
$sreturn &= $schr
Next
Return $sreturn
EndFunc
Func _stringtohex($sstring)
Return Hex(StringToBinary($sstring, $sb_utf8))
EndFunc
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$linguistic_ignorecase = 16
$linguistic_ignorediacritic = 32
$norm_ignorecase = 1
$norm_ignorekanatype = 65536
$norm_ignorenonspace = 2
$norm_ignoresymbols = 4
$norm_ignorewidth = 131072
$norm_linguistic_casing = 134217728
$sort_digitsasnumbers = 8
$sort_stringsort = 4096
$cstr_less_than = 1
$cstr_equal = 2
$cstr_greater_than = 3
$mui_language_id = 4
$mui_language_name = 8
$date_autolayout = 64
$date_longdate = 2
$date_ltrreading = 16
$date_shortdate = 1
$date_rtlreading = 32
$date_use_alt_calendar = 4
$date_yearmonth = 8
$geo_nation = 1
$geo_latitude = 2
$geo_longitude = 3
$geo_iso2 = 4
$geo_iso3 = 5
$geo_rfc1766 = 6
$geo_lcid = 7
$geo_friendlyname = 8
$geo_officialname = 9
$geo_timezones = 10
$geo_officiallanguages = 11
$geo_iso_un_number = 12
$geo_parent = 13
$locale_ilanguage = 1
$locale_slanguage = 2
$locale_senglanguage = 4097
$locale_sabbrevlangname = 3
$locale_snativelangname = 4
$locale_icountry = 5
$locale_scountry = 6
$locale_sengcountry = 4098
$locale_sabbrevctryname = 7
$locale_snativectryname = 8
$locale_idefaultlanguage = 9
$locale_idefaultcountry = 10
$locale_idefaultcodepage = 11
$locale_idefaultansicodepage = 4100
$locale_idefaultmaccodepage = 4113
$locale_slist = 12
$locale_imeasure = 13
$locale_sdecimal = 14
$locale_sthousand = 15
$locale_sgrouping = 16
$locale_idigits = 17
$locale_ilzero = 18
$locale_inegnumber = 4112
$locale_snativedigits = 19
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$locale_scurrency = 20
$locale_sintlsymbol = 21
$locale_smondecimalsep = 22
$locale_smonthousandsep = 23
$locale_smongrouping = 24
$locale_icurrdigits = 25
$locale_iintlcurrdigits = 26
$locale_icurrency = 27
$locale_inegcurr = 28
$locale_sdate = 29
$locale_stime = 30
$locale_sshortdate = 31
$locale_slongdate = 32
$locale_stimeformat = 4099
$locale_idate = 33
$locale_ildate = 34
$locale_itime = 35
$locale_itimemarkposn = 4101
$locale_icentury = 36
$locale_itlzero = 37
$locale_idaylzero = 38
$locale_imonlzero = 39
$locale_s1159 = 40
$locale_s2359 = 41
$locale_icalendartype = 4105
$locale_ioptionalcalendar = 4107
$locale_ifirstdayofweek = 4108
$locale_ifirstweekofyear = 4109
$locale_sdayname1 = 42
$locale_sdayname2 = 43
$locale_sdayname3 = 44
$locale_sdayname4 = 45
$locale_sdayname5 = 46
$locale_sdayname6 = 47
$locale_sdayname7 = 48
$locale_sabbrevdayname1 = 49
$locale_sabbrevdayname2 = 50
$locale_sabbrevdayname3 = 51
$locale_sabbrevdayname4 = 52
$locale_sabbrevdayname5 = 53
$locale_sabbrevdayname6 = 54
$locale_sabbrevdayname7 = 55
$locale_smonthname1 = 56
$locale_smonthname2 = 57
$locale_smonthname3 = 58
$locale_smonthname4 = 59
$locale_smonthname5 = 60
$locale_smonthname6 = 61
$locale_smonthname7 = 62
$locale_smonthname8 = 63
$locale_smonthname9 = 64
$locale_smonthname10 = 65
$locale_smonthname11 = 66
$locale_smonthname12 = 67
$locale_smonthname13 = 4110
$locale_sabbrevmonthname1 = 68
$locale_sabbrevmonthname2 = 69
$locale_sabbrevmonthname3 = 70
$locale_sabbrevmonthname4 = 71
$locale_sabbrevmonthname5 = 72
"]")
EndFunc
DllStructSetData($tfmt,
DllStructSetData($tfmt,
DllStructSetData($tfmt,
DllStructSetData($tfmt,
DllStructSetData($tfmt,
DllStructSetData($tfmt,
DllStructSetData($tfmt,
DllStructSetData($tfmt,
Return $tfmt
1,
2,
3,
4,
5,
6,
7,
8,
$inumdigits)
$ileadingzero)
$igrouping)
DllStructGetPtr($tfmt, 7))
DllStructGetPtr($tfmt, 8))
$inegativeorder)
$sdecimalsep)
$sthousandsep)
Func _winapi_enumsystemgeoid()
Local $henumproc = DllCallbackRegister("__EnumGeoIDProc"
, "bool", "long")
Dim $__g_venum[101] = [0]
Local $aret = DllCall("kernel32.dll", "bool", "EnumSyste
mGeoID", "dword", 16, "long", 0, "ptr", DllCallbackGetPtr($henumproc))
If @error OR NOT $aret[0] OR NOT $__g_venum[0] Then
$__g_venum = @error + 10
EndIf
DllCallbackFree($henumproc)
If $__g_venum Then Return SetError($__g_venum, 0, 0)
__inc($__g_venum, -1)
Return $__g_venum
EndFunc
Func _winapi_enumsystemlocales($iflag)
Local $henumproc = DllCallbackRegister("__EnumLocalesPro
c", "bool", "ptr")
Dim $__g_venum[101] = [0]
Local $aret = DllCall("kernel32.dll", "bool", "EnumSyste
mLocalesW", "ptr", DllCallbackGetPtr($henumproc), "dword", $iflag)
If @error OR NOT $aret[0] OR NOT $__g_venum[0] Then
$__g_venum = @error + 10
EndIf
DllCallbackFree($henumproc)
If $__g_venum Then Return SetError($__g_venum, 0, 0)
__inc($__g_venum, -1)
Return $__g_venum
EndFunc
Func _winapi_enumuilanguages($iflag = 0)
Local $henumproc = DllCallbackRegister("__EnumUILanguage
sProc", "bool", "ptr;long_ptr")
Local $iid = 1
If $__winver >= 1536 Then
If BitAND($iflag, 8) Then
$iid = 0
EndIf
Else
$iflag = 0
EndIf
Dim $__g_venum[101] = [0]
Local $aret = DllCall("kernel32.dll", "bool", "EnumUILan
guagesW", "ptr", DllCallbackGetPtr($henumproc), "dword", $iflag, "long_ptr", $ii
d)
If @error OR NOT $aret[0] OR NOT $__g_venum[0] Then
$__g_venum = @error + 10
EndIf
EndFunc
DllCallbackFree($henumproc)
If $__g_venum Then Return SetError($__g_venum, 0, 0)
__inc($__g_venum, -1)
Return $__g_venum
striptrailing) Then
EndIf
Local $aret = DllCall("kernel32.dll", "int", "GetDuratio
nFormat", "dword", $ilcid, "dword", 0, "ptr", $pst, "uint64", $ival, $stypeoffor
mat, $sformat, "wstr", "", "int", 2048)
If @error OR NOT $aret[0] Then Return SetError(@error, @
extended, "")
Return $aret[6]
EndFunc
Func _winapi_getgeoinfo($igeoid, $itype, $ilanguage = 0)
Local $aret = DllCall("kernel32.dll", "int", "GetGeoInfo
W", "long", $igeoid, "dword", $itype, "wstr", "", "int", 4096, "word", $ilanguag
e)
If @error OR NOT $aret[0] Then Return SetError(@error, @
extended, 0)
Return $aret[3]
EndFunc
Func _winapi_getlocaleinfo($ilcid, $itype)
Local $aret = DllCall("kernel32.dll", "int", "GetLocaleI
nfoW", "dword", $ilcid, "dword", $itype, "wstr", "", "int", 2048)
DefaultLangID")
Func _winapi_getsystemdefaultlangid()
Local $aret = DllCall("kernel32.dll", "word", "GetSystem
EndFunc
mDefaultLCID")
Func _winapi_getsystemdefaultlcid()
Local $aret = DllCall("kernel32.dll", "dword", "GetSyste
EndFunc
Func _winapi_getsystemdefaultuilanguage()
Local $aret = DllCall("kernel32.dll", "word", "GetSystem
DefaultUILanguage")
If @error Then Return SetError(@error, @extended, 0)
Return $aret[0]
EndFunc
dLocale")
Func _winapi_getthreadlocale()
Local $aret = DllCall("kernel32.dll", "dword", "GetThrea
EndFunc
UILanguage")
Func _winapi_getthreaduilanguage()
Local $aret = DllCall("kernel32.dll", "word", "GetThread
EndFunc
faultLangID")
Func _winapi_getuserdefaultlangid()
Local $aret = DllCall("kernel32.dll", "word", "GetUserDe
EndFunc
efaultLCID")
Func _winapi_getuserdefaultlcid()
Local $aret = DllCall("kernel32.dll", "dword", "GetUserD
EndFunc
Func _winapi_getuserdefaultuilanguage()
Local $aret = DllCall("kernel32.dll", "word", "GetUserDe
faultUILanguage")
If @error Then Return SetError(@error, @extended, 0)
Return $aret[0]
EndFunc
Func _winapi_getusergeoid()
Local $aret = DllCall("kernel32.dll", "long", "GetUserGe
oID", "uint", 16)
If @error Then Return SetError(@error, @extended, -1)
Return $aret[0]
EndFunc
Func _winapi_isvalidlocale($ilcid, $iflag = 0)
Local $aret = DllCall("kernel32.dll", "bool", "IsValidLo
cale", "dword", $ilcid, "dword", $iflag)
If @error Then Return SetError(@error, @extended, False)
Return $aret[0]
EndFunc
Func _winapi_setlocaleinfo($ilcid, $itype, $sdata)
Local $aret = DllCall("kernel32.dll", "bool", "SetLocale
InfoW", "dword", $ilcid, "dword", $itype, "wstr", $sdata)
If @error Then Return SetError(@error, @extended, False)
Return $aret[0]
EndFunc
Func _winapi_setthreadlocale($ilcid)
Local $aret = DllCall("kernel32.dll", "bool", "SetThread
Locale", "dword", $ilcid)
If @error Then Return SetError(@error, @extended, False)
Return $aret[0]
EndFunc
Func _winapi_setthreaduilanguage($ilanguage)
Local $aret = DllCall("kernel32.dll", "word", "SetThread
UILanguage", "word", $ilanguage)
If @error Then Return SetError(@error, @extended, False)
EndFunc
Func _winapi_setusergeoid($igeoid)
Local $aret = DllCall("kernel32.dll", "bool", "SetUserGe
oID", "long", $igeoid)
If @error Then Return SetError(@error, @extended, False)
Return $aret[0]
EndFunc
#EndRegion Public Functions
#Region Internal Functions
Func __enumgeoidproc($iid)
__inc($__g_venum)
$__g_venum[$__g_venum[0]] = $iid
Return 1
EndFunc
Func __enumlocalesproc($plocale)
__inc($__g_venum)
$__g_venum[$__g_venum[0]] = Dec(DllStructGetData(DllStru
ctCreate("wchar[" & (_winapi_strlen($plocale) + 1) & "]", $plocale), 1))
Return 1
EndFunc
Func __enumuilanguagesproc($planguage, $iid)
__inc($__g_venum)
$__g_venum[$__g_venum[0]] = DllStructGetData(DllStructCr
eate("wchar[" & (_winapi_strlen($planguage) + 1) & "]", $planguage), 1)
If $iid Then
$__g_venum[$__g_venum[0]] = Dec($__g_venum[$__g_
venum[0]])
EndIf
Return 1
EndFunc
#EndRegion Internal Functions
Func _dateadd($stype, $inumber, $sdate)
Local $astimepart[4]
Local $asdatepart[4]
Local $ijuliandate
$stype = StringLeft($stype, 1)
If StringInStr("D,M,Y,w,h,n,s", $stype) = 0 OR $stype = "" Then
Return SetError(1, 0, 0)
EndIf
If NOT StringIsInt($inumber) Then
Return SetError(2, 0, 0)
EndIf
If NOT _dateisvalid($sdate) Then
Return SetError(3, 0, 0)
EndIf
_datetimesplit($sdate, $asdatepart, $astimepart)
If $stype = "d" OR $stype = "w" Then
If $stype = "w" Then $inumber = $inumber * 7
$ijuliandate = _datetodayvalue($asdatepart[1], $asdatepa
rt[2], $asdatepart[3]) + $inumber
_dayvaluetodate($ijuliandate, $asdatepart[1], $asdatepar
t[2], $asdatepart[3])
EndIf
If $stype = "m" Then
$asdatepart[2] = $asdatepart[2] + $inumber
While $asdatepart[2] > 12
$asdatepart[2] = $asdatepart[2] - 12
$asdatepart[1] = $asdatepart[1] + 1
WEnd
While $asdatepart[2] < 1
$asdatepart[2] = $asdatepart[2] + 12
$asdatepart[1] = $asdatepart[1] - 1
WEnd
EndIf
If $stype = "y" Then
$asdatepart[1] = $asdatepart[1] + $inumber
EndIf
If $stype = "h" OR $stype = "n" OR $stype = "s" Then
Local $itimeval = _timetoticks($astimepart[1], $astimepa
rt[2], $astimepart[3]) / 1000
If $stype = "h" Then $itimeval = $itimeval + $inumber *
3600
If $stype = "n" Then $itimeval = $itimeval + $inumber *
60
If $stype = "s" Then $itimeval = $itimeval + $inumber
Local $iday2add = Int($itimeval / (24 * 60 * 60))
$itimeval = $itimeval - $iday2add * 24 * 60 * 60
If $itimeval < 0 Then
$iday2add = $iday2add - 1
$itimeval = $itimeval + 24 * 60 * 60
EndIf
$ijuliandate = _datetodayvalue($asdatepart[1], $asdatepa
rt[2], $asdatepart[3]) + $iday2add
_dayvaluetodate($ijuliandate, $asdatepart[1], $asdatepar
t[2], $asdatepart[3])
_tickstotime($itimeval * 1000, $astimepart[1], $astimepa
rt[2], $astimepart[3])
EndIf
Local $inumdays = _daysinmonth($asdatepart[1])
If $inumdays[$asdatepart[2]] < $asdatepart[3] Then $asdatepart[3
] = $inumdays[$asdatepart[2]]
$sdate = $asdatepart[1] & "/" & StringRight("0" & $asdatepart[2]
, 2) & "/" & StringRight("0" & $asdatepart[3], 2)
If $astimepart[0] > 0 Then
If $astimepart[0] > 2 Then
$sdate = $sdate & " " & StringRight("0" & $astim
epart[1], 2) & ":" & StringRight("0" & $astimepart[2], 2) & ":" & StringRight("0
" & $astimepart[3], 2)
Else
$sdate = $sdate & " " & StringRight("0" & $astim
epart[1], 2) & ":" & StringRight("0" & $astimepart[2], 2)
EndIf
EndIf
Return $sdate
EndFunc
Func _datedayofweek($idaynum, $iformat = Default)
Local Const $monday_is_no1 = 128
If $iformat = Default Then $iformat = 0
$idaynum = Int($idaynum)
If $idaynum < 1 OR $idaynum > 7 Then Return SetError(1, 0, "")
Local $tsystemtime = DllStructCreate($tagsystemtime)
Func _dateisleapyear($iyear)
If StringIsInt($iyear) Then
Select
Case Mod($iyear, 4) = 0 AND Mod($iyear, 100) <>
Return 1
Case Mod($iyear, 400) = 0
Return 1
Case Else
Return 0
EndSelect
EndFunc
EndIf
Return SetError(1, 0, 0)
Func __dateismonth($inumber)
$inumber = Int($inumber)
Return $inumber >= 1 AND $inumber <= 12
EndFunc
Func _dateisvalid($sdate)
Local $asdatepart[4], $astimepart[4]
_datetimesplit($sdate, $asdatepart, $astimepart)
If NOT StringIsInt($asdatepart[1]) Then Return 0
If NOT StringIsInt($asdatepart[2]) Then Return 0
If NOT StringIsInt($asdatepart[3]) Then Return 0
$asdatepart[1] = Int($asdatepart[1])
$asdatepart[2] = Int($asdatepart[2])
$asdatepart[3] = Int($asdatepart[3])
Local $inumdays = _daysinmonth($asdatepart[1])
If $asdatepart[1] < 1000 OR $asdatepart[1] > 2999 Then Return 0
If $asdatepart[2] < 1 OR $asdatepart[2] > 12 Then Return 0
If $asdatepart[3] < 1 OR $asdatepart[3] > $inumdays[$asdatepart[
2]] Then Return 0
If $astimepart[0] < 1 Then Return 1
If $astimepart[0] < 2 Then Return 0
If $astimepart[0] = 2 Then $astimepart[3] = "00"
If NOT StringIsInt($astimepart[1]) Then Return 0
If NOT StringIsInt($astimepart[2]) Then Return 0
If NOT StringIsInt($astimepart[3]) Then Return 0
$astimepart[1] = Int($astimepart[1])
$astimepart[2] = Int($astimepart[2])
$astimepart[3] = Int($astimepart[3])
If $astimepart[1] < 0 OR $astimepart[1] > 23 Then Return 0
If $astimepart[2] < 0 OR $astimepart[2] > 59 Then Return 0
If $astimepart[3] < 0 OR $astimepart[3] > 59 Then Return 0
Return 1
EndFunc
Func __dateisyear($inumber)
Return StringLen($inumber) = 4
EndFunc
Func _datelastweekdaynum($iweekdaynum)
Select
Case NOT StringIsInt($iweekdaynum)
Return SetError(1, 0, 0)
Case $iweekdaynum < 1 OR $iweekdaynum > 7
Return SetError(2, 0, 0)
Case Else
Local $ilastweekdaynum
If $iweekdaynum = 1 Then
$ilastweekdaynum = 7
Else
$ilastweekdaynum = $iweekdaynum - 1
EndIf
Return $ilastweekdaynum
EndSelect
EndFunc
hnum)
Func _datelastmonthnum($imonthnum)
Select
Case NOT StringIsInt($imonthnum)
Return SetError(1, 0, 0)
Case NOT __dateismonth($imonthnum)
Return SetError(2, 0, 0)
Case Else
Local $ilastmonthnum
If $imonthnum = 1 Then
$ilastmonthnum = 12
Else
$ilastmonthnum = $imonthnum - 1
EndIf
$ilastmonthnum = StringFormat("%02d", $ilastmont
Return $ilastmonthnum
EndFunc
ar)
EndSelect
EndFunc
Return SetError(1, 0, 0)
Case NOT __dateismonth($imonthnum)
Return SetError(2, 0, 0)
Case Else
Local $ilastyear
If $imonthnum = 1 Then
$ilastyear = $iyear - 1
Else
$ilastyear = $iyear
EndIf
$ilastyear = StringFormat("%04d", $ilastyear)
Return $ilastyear
EndSelect
Func _datenextweekdaynum($iweekdaynum)
Select
Case NOT StringIsInt($iweekdaynum)
Return SetError(1, 0, 0)
Case $iweekdaynum < 1 OR $iweekdaynum > 7
Return SetError(2, 0, 0)
Case Else
Local $inextweekdaynum
If $iweekdaynum = 7 Then
$inextweekdaynum = 1
Else
$inextweekdaynum = $iweekdaynum + 1
EndIf
Return $inextweekdaynum
EndSelect
EndFunc
hnum)
Func _datenextmonthnum($imonthnum)
Select
Case NOT StringIsInt($imonthnum)
Return SetError(1, 0, 0)
Case NOT __dateismonth($imonthnum)
Return SetError(2, 0, 0)
Case Else
Local $inextmonthnum
If $imonthnum = 12 Then
$inextmonthnum = 1
Else
$inextmonthnum = $imonthnum + 1
EndIf
$inextmonthnum = StringFormat("%02d", $inextmont
EndFunc
EndSelect
Return $inextmonthnum
ar)
EndFunc
Return SetError(1, 0, 0)
Case NOT __dateismonth($imonthnum)
Return SetError(2, 0, 0)
Case Else
Local $inextyear
If $imonthnum = 12 Then
$inextyear = $iyear + 1
Else
$inextyear = $iyear
EndIf
$inextyear = StringFormat("%04d", $inextyear)
Return $inextyear
EndSelect
Else
Case 3
EndIf
$stempdate = "M/d/yyyy"
t, $locale_s1159)
t, $locale_s2359)
t, $locale_stime)
mpstring)
tt", $sam)
] = 12
tt", $spm)
1] = $astimepart[1] - 12
EndIf
EndIf
$astimepart[1] = StringRight("0" & $astimepart[1], 2)
$astimepart[2] = StringRight("0" & $astimepart[2], 2)
$astimepart[3] = StringRight("0" & $astimepart[3], 2)
$stemptime = StringReplace($stemptime, "hh", StringForma
t("%02d", $astimepart[1]))
$stemptime = StringReplace($stemptime, "h", StringReplac
e(StringLeft($astimepart[1], 1), "0", "") & StringRight($astimepart[1], 1))
$stemptime = StringReplace($stemptime, "mm", StringForma
t("%02d", $astimepart[2]))
$stemptime = StringReplace($stemptime, "ss", StringForma
t("%02d", $astimepart[3]))
$stempdate = StringStripWS($stempdate & " " & $stemptime
, $str_stripleading + $str_striptrailing)
EndIf
Return $stempdate
EndFunc
Func _datetimesplit($sdate, ByRef $adatepart, ByRef $itimepart)
Local $sdatetime = StringSplit($sdate, " T")
If $sdatetime[0] > 0 Then $adatepart = StringSplit($sdatetime[1]
, "/-.")
If $sdatetime[0] > 1 Then
$itimepart = StringSplit($sdatetime[2], ":")
If UBound($itimepart) < 4 Then ReDim $itimepart[4]
Else
Dim $itimepart[4]
EndIf
If UBound($adatepart) < 4 Then ReDim $adatepart[4]
EndFunc
For $x = 1 To 3
If StringIsInt($adatepart[$x]) Then
$adatepart[$x] = Int($adatepart[$x])
Else
$adatepart[$x] = -1
EndIf
If StringIsInt($itimepart[$x]) Then
$itimepart[$x] = Int($itimepart[$x])
Else
$itimepart[$x] = 0
EndIf
Next
Return 1
EndFunc
$ssep, $idays)
EndFunc
Func _now()
Return _datetimeformat(@YEAR & "/" & @MON & "/" & @MDAY & " " &
@HOUR & ":" & @MIN & ":" & @SEC, 0)
EndFunc
Func _nowcalc()
Return @YEAR & "/" & @MON & "/" & @MDAY & " " & @HOUR & ":" & @M
IN & ":" & @SEC
EndFunc
Func _nowcalcdate()
Return @YEAR & "/" & @MON & "/" & @MDAY
EndFunc
Func _nowdate()
Return _datetimeformat(@YEAR & "/" & @MON & "/" & @MDAY, 0)
EndFunc
Func _nowtime($stype = 3)
If $stype < 3 OR $stype > 5 Then $stype = 3
Return _datetimeformat(@YEAR & "/" & @MON & "/" & @MDAY & " " &
@HOUR & ":" & @MIN & ":" & @SEC, $stype)
EndFunc
eturn 1
temtime)
nth)
EndFunc
Func _settime($ihour,
If $ihour < 0
If $iminute <
If $isecond <
temtime)
isecond)
, $imseconds)
EndFunc
)) Then
$imonth = 12
$iday = 31
$iyear = $iyear - 1
ElseIf ($imonth = 12 AND 30 - ($iday - 1) < _datetodayofweekiso(
$iyear + 1, 1, 1) - 1 AND _datetodayofweekiso($iyear + 1, 1, 1) - 1 < 4) Then
Return 1
EndIf
Return Int((_datetodayofweekiso($iyear, 1, 1) - 1 < 4) + 4 * ($i
month - 1) + (2 * ($imonth - 1) + ($iday - 1) + $idow0101 - $idow + 6) * 36 / 25
6)
EndFunc
Func _weeknumber($iyear = @YEAR, $imonth = @MON, $iday = @MDAY, $iweekst
art = 1)
If $iday > 31 OR $iday < 1 Then
Return SetError(1, 0, -1)
ElseIf NOT __dateismonth($imonth) Then
Return SetError(3, 0, -1)
ElseIf $iyear < 1 OR $iyear > 2999 Then
Return SetError(4, 0, -1)
ElseIf $iweekstart < 1 OR $iweekstart > 2 Then
Return SetError(2, 0, -1)
EndIf
Local $istartweek1, $iendweek1
Local $idow0101 = _datetodayofweekiso($iyear, 1, 1)
Local $idate = $iyear & "/" & $imonth & "/" & $iday
If $iweekstart = 1 Then
If $idow0101 = 6 Then
$istartweek1 = 0
Else
$istartweek1 = -1 * $idow0101 - 1
EndIf
$iendweek1 = $istartweek1 + 6
Else
$istartweek1 = $idow0101 * -1
$iendweek1 = $istartweek1 + 6
EndIf
Local $istartweek1ny
Local $iendweek1date = _dateadd("d", $iendweek1, $iyear & "/01/0
1")
Local $idow0101ny = _datetodayofweekiso($iyear + 1, 1, 1)
If $iweekstart = 1 Then
If $idow0101ny = 6 Then
$istartweek1ny = 0
Else
$istartweek1ny = -1 * $idow0101ny - 1
EndIf
Else
$istartweek1ny = $idow0101ny * -1
EndIf
Local $istartweek1dateny = _dateadd("d", $istartweek1ny, $iyear
+ 1 & "/01/01")
Local $icurrdatediff = _datediff("d", $iendweek1date, $idate) 1
Local $icurrdatediffny = _datediff("d", $istartweek1dateny, $ida
te)
If $icurrdatediff >= 0 AND $icurrdatediffny < 0 Then Return 2 +
Int($icurrdatediff / 7)
If $icurrdatediff < 0 OR $icurrdatediffny >= 0 Then Return 1
EndFunc
Func _daysinmonth($iyear)
Local $adays = [12, 31, (_dateisleapyear($iyear) ? 29 : 28), 31,
30, 31, 30, 31, 31, 30, 31, 30, 31]
Return $adays
EndFunc
me)
Func __date_time_clonesystemtime($psystemtime)
Local $tsystemtime1 = DllStructCreate($tagsystemtime, $psystemti
EndFunc
e)
te[2])
Func _date_time_dosdatetostr($idosdate)
Local $adate = _date_time_dosdatetoarray($idosdate)
Return StringFormat("%02d/%02d/%04d", $adate[0], $adate[1], $ada
EndFunc
Func _date_time_dostimetoarray($idostime)
Local $atime[3]
$atime[2] = BitAND($idostime, 31) * 2
$atime[1] = BitAND(BitShift($idostime, 5), 63)
$atime[0] = BitAND(BitShift($idostime, 11), 31)
Return $atime
EndFunc
me[2])
Func _date_time_dostimetostr($idostime)
Local $atime = _date_time_dostimetoarray($idostime)
Return StringFormat("%02d:%02d:%02d", $atime[0], $atime[1], $ati
EndFunc
ttime)
Func _date_time_getlocaltime()
Local $tsysttime = DllStructCreate($tagsystemtime)
DllCall("kernel32.dll", "none", "GetLocalTime", "struct*", $tsys
EndFunc
Func _date_time_getsystemtime()
Local $tsysttime = DllStructCreate($tagsystemtime)
DllCall("kernel32.dll", "none", "GetSystemTime", "struct*", $tsy
sttime)
EndFunc
Func _date_time_getsystemtimeadjustment()
Local $ainfo[3]
Local $aresult = DllCall("kernel32.dll", "bool", "GetSystemTimeA
djustment", "dword*", 0, "dword*", 0, "bool*", 0)
If @error Then Return SetError(@error, @extended, 0)
$ainfo[0] = $aresult[1]
$ainfo[1] = $aresult[2]
$ainfo[2] = $aresult[3] <> 0
Return SetExtended($aresult[0], $ainfo)
EndFunc
Func _date_time_getsystemtimeasfiletime()
Local $tfiletime = DllStructCreate($tagfiletime)
DllCall("kernel32.dll", "none", "GetSystemTimeAsFileTime", "stru
ct*", $tfiletime)
If @error Then Return SetError(@error, @extended, 0)
Return $tfiletime
EndFunc
Func _date_time_getsystemtimes()
Local $ainfo[3]
$ainfo[0] = DllStructCreate($tagfiletime)
$ainfo[1] = DllStructCreate($tagfiletime)
$ainfo[2] = DllStructCreate($tagfiletime)
Local $aresult = DllCall("kernel32.dll", "bool", "GetSystemTimes
", "struct*", $ainfo[0], "struct*", $ainfo[1], "struct*", $ainfo[2])
If @error Then Return SetError(@error, @extended, 0)
Return SetExtended($aresult[0], $ainfo)
EndFunc
Func _date_time_gettickcount()
Local $aresult = DllCall("kernel32.dll", "dword", "GetTickCount"
EndFunc
Func _date_time_gettimezoneinformation()
Local $ttimezone = DllStructCreate($tagtime_zone_information)
Local $aresult = DllCall("kernel32.dll", "dword", "GetTimeZoneIn
formation", "struct*", $ttimezone)
If @error OR $aresult[0] = -1 Then Return SetError(@error, @exte
nded, 0)
Local $ainfo[8]
$ainfo[0] = $aresult[0]
$ainfo[1] = DllStructGetData($ttimezone, "Bias")
$ainfo[2] = _winapi_widechartomultibyte(DllStructGetPtr($ttimezo
ne, "StdName"))
$ainfo[3] = __date_time_clonesystemtime(DllStructGetPtr($ttimezo
ne, "StdDate"))
$ainfo[4] = DllStructGetData($ttimezone, "StdBias")
$ainfo[5] = _winapi_widechartomultibyte(DllStructGetPtr($ttimezo
ne, "DayName"))
$ainfo[6] = __date_time_clonesystemtime(DllStructGetPtr($ttimezo
ne, "DayDate"))
EndFunc
Func _date_time_localfiletimetofiletime($tlocaltime)
Local $tfiletime = DllStructCreate($tagfiletime)
Local $aresult = DllCall("kernel32.dll", "bool", "LocalFileTimeT
oFileTime", "struct*", $tlocaltime, "struct*", $tfiletime)
If @error Then Return SetError(@error, @extended, 0)
Return SetExtended($aresult[0], $tfiletime)
EndFunc
ite)
, False)
EndFunc
EndFunc
fo[5])
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$inet_localcache = 0
$inet_forcereload = 1
$inet_ignoressl = 2
$inet_asciitransfer = 4
$inet_binarytransfer = 8
$inet_forcebypass = 16
$inet_downloadwait = 0
$inet_downloadbackground = 1
$inet_downloadread = 0
$inet_downloadsize = 1
$inet_downloadcomplete = 2
$inet_downloadsuccess = 3
$inet_downloaderror = 4
$inet_downloadextended = 5
Func _getip()
Local Const $getip_timer = 300000
Local Static $htimer = 0
Local Static $slastip = 0
If TimerDiff($htimer) < $getip_timer AND NOT $slastip Then
Return SetExtended(1, $slastip)
EndIf
Local $agetipurl[] = ["http://checkip.dyndns.org", "http://www.m
yexternalip.com/raw", "http://bot.whatismyipaddress.com"], $areturn = 0, $sretur
n = ""
For $i = 0 To UBound($agetipurl) - 1
$sreturn = InetRead($agetipurl[$i])
If @error OR $sreturn == "" Then ContinueLoop
$areturn = StringRegExp(BinaryToString($sreturn), "((?:\
d{1,3}\.){3}\d{1,3})", $str_regexparrayglobalmatch)
If NOT @error Then
$sreturn = $areturn[0]
ExitLoop
EndIf
$sreturn = ""
Next
$htimer = TimerInit()
$slastip = $sreturn
If $sreturn == "" Then Return SetError(1, 0, -1)
Return $sreturn
EndFunc
Func _inetexplorercapable($siestring)
If StringLen($siestring) <= 0 Then Return SetError(1, 0, "")
Local $s_iereturn
Local $n_iechar
For $i_iecount = 1 To StringLen($siestring)
$n_iechar = "0x" & Hex(Asc(StringMid($siestring, $i_ieco
unt, 1)), 2)
If $n_iechar < 33 OR $n_iechar = 37 OR $n_iechar = 47 OR
$n_iechar > 127 Then
$s_iereturn = $s_iereturn & "%" & StringRight($n
_iechar, 2)
Else
$s_iereturn = $s_iereturn & Chr($n_iechar)
EndIf
Next
Return $s_iereturn
EndFunc
LF
4 + 16, "", 8)
EndFunc
If WinExists($sw_title) Then
ControlSetText($sw_title, "", "Static1", $ssmtptrace)
Else
SplashTextOn($sw_title, $ssmtptrace, 400, 500, 500, 100,
EndIf
If $itimeout Then Sleep($itimeout * 1000)
$sreceive = ""
$htimer = TimerInit()
While StringLeft($sreceive, StringLen($sintreply)) <> $s
intreply AND TimerDiff($htimer) < 45000
$sreceive = TCPRecv($vsocket, 1000)
If $btrace AND $sreceive <> "" Then __smtptrace(
"intermediate->" & $sreceive)
WEnd
EndIf
If TCPSend($vsocket, $ssend) = 0 Then
TCPCloseSocket($vsocket)
TCPShutdown()
Return 1
EndIf
$htimer = TimerInit()
$sreceive = ""
While $sreceive = "" AND TimerDiff($htimer) < 45000
$i += 1
$sreceive = TCPRecv($vsocket, 1000)
If $sreplycode = "" Then ExitLoop
WEnd
If $sreplycode <> "" Then
If $btrace Then __smtptrace($i & " <- " & $sreceive)
If StringLeft($sreceive, StringLen($sreplycode)) <> $sre
plycode Then
TCPCloseSocket($vsocket)
TCPShutdown()
If $btrace Then __smtptrace("<-> " & $sreplycode
, 5)
Return 2
EndIf
EndIf
Return 0
EndFunc
sip)
SetError(@error + 1)
Return 0
EndIf
DllCall($ah_handle[0], "int", "ReadProcessMemory", "int"
, $ah_handle[1], "int", $iv_address, "ptr", DllStructGetPtr($v_buffer), "int", D
llStructGetSize($v_buffer), "int", "")
If NOT @error Then
Local $v_value = DllStructGetData($v_buffer, 1)
Return $v_value
Else
SetError(6)
Return 0
EndIf
EndFunc
dword")
handle[1])
Func _memoryclose($ah_handle)
If NOT IsArray($ah_handle) Then
SetError(1)
Return 0
EndIf
DllCall($ah_handle[0], "int", "CloseHandle", "int", $ah_
EndFunc
#EndRegion
Global $__binarycall_kernel32dll = DllOpen("kernel32.dll")
Global $__binarycall_msvcrtdll = DllOpen("msvcrt.dll")
Global $__binarycall_lasterror = ""
Func _binarycall_getprocaddress($module, $proc)
Local $ret = DllCall($__binarycall_kernel32dll, "ptr", "GetProcA
ddress", "ptr", $module, "str", $proc)
If @error OR NOT $ret[0] Then Return SetError(1, @error, 0)
Return $ret[0]
EndFunc
Func _binarycall_loadlibrary($filename)
Local $ret = DllCall($__binarycall_kernel32dll, "handle", "LoadL
ibraryW", "wstr", $filename)
If @error Then Return SetError(1, @error, 0)
Return $ret[0]
EndFunc
Func _binarycall_lstrlena($ptr)
Local $ret = DllCall($__binarycall_kernel32dll, "int", "lstrlenA
", "ptr", $ptr)
If @error Then Return SetError(1, @error, 0)
Return $ret[0]
EndFunc
Func _binarycall_alloc($code, $padding = 0)
Local $length = BinaryLen($code) + $padding
Local $ret = DllCall($__binarycall_kernel32dll, "ptr", "VirtualA
lloc", "ptr", 0, "ulong_ptr", $length, "dword", 4096, "dword", 64)
If @error OR NOT $ret[0] Then Return SetError(1, @error, 0)
If BinaryLen($code) Then
Local $buffer = DllStructCreate("byte[" & $length & "]",
$ret[0])
DllStructSetData($buffer, 1, $code)
EndIf
Return $ret[0]
EndFunc
Func _binarycall_regionsize($ptr)
Local $buffer = DllStructCreate("ptr;ptr;dword;uint_ptr;dword;dw
ord;dword")
Local $ret = DllCall($__binarycall_kernel32dll, "int", "VirtualQ
uery", "ptr", $ptr, "ptr", DllStructGetPtr($buffer), "uint_ptr", DllStructGetSiz
e($buffer))
If @error OR $ret[0] = 0 Then Return SetError(1, @error, 0)
Return DllStructGetData($buffer, 4)
EndFunc
Func _binarycall_free($ptr)
Local $ret = DllCall($__binarycall_kernel32dll, "bool", "Virtual
Free", "ptr", $ptr, "ulong_ptr", 0, "dword", 32768)
If @error OR $ret[0] = 0 Then
$ret = DllCall($__binarycall_kernel32dll, "bool", "Globa
EndIf
Return True
Func _binarycall_release($codebase)
Local $ret = _binarycall_free($codebase)
Return SetError(@error, @extended, $ret)
EndFunc
Func _binarycall_memorysearch($ptr, $length, $binary)
Static $codebase
If NOT $codebase Then
If @AutoItX64 Then
$codebase = _binarycall_create("0x4883EC084D85C9
4889C8742C4C39CA72254C29CA488D141131C9EB0848FFC14C39C97414448A1408453A140874EE48
FFC04839D076E231C05AC3", "", 0, True, False)
Else
$codebase = _binarycall_create("0x5589E58B4D1457
8B4508568B550C538B7D1085C9742139CA721B29CA8D341031D2EB054239CA740F8A1C17381C1074
F34039F076EA31C05B5E5F5DC3", "", 0, True, False)
EndIf
If NOT $codebase Then Return SetError(1, 0, 0)
EndIf
$binary = Binary($binary)
Local $buffer = DllStructCreate("byte[" & BinaryLen($binary) & "
]")
DllStructSetData($buffer, 1, $binary)
Local $ret = DllCallAddress("ptr:cdecl", $codebase, "ptr", $ptr,
"uint", $length, "ptr", DllStructGetPtr($buffer), "uint", DllStructGetSize($buf
fer))
Return $ret[0]
EndFunc
Func _binarycall_base64decode($src)
Static $codebase
If NOT $codebase Then
If @AutoItX64 Then
$codebase = _binarycall_create("0x41544989CAB9FF
000000555756E8BE000000534881EC000100004889E7F3A44C89D6E98A0000004439C87E0731C0E9
8D0000000FB66E01440FB626FFC00FB65E020FB62C2C460FB62424408A3C1C0FB65E034189EB41C1
E4024183E3308A1C1C41C1FB044509E34080FF634189CC45881C08744C440FB6DFC1E5044489DF40
88E883E73CC1FF0209C7418D44240241887C08014883C10380FB63742488D841C1E3064883C60483
E03F4409D841884408FF89F389C84429D339D30F8C67FFFFFF4881C4000100005B5E5F5D415CC35E
C3E8F9FFFFFF00000000000000000000000000000000000000000000000000000000000000000000
0000000000000000003E0000003F3435363738393A3B3C3D00000063000000000102030405060708
090A0B0C0D0E0F101112131415161718190000000000001A1B1C1D1E1F202122232425262728292A
2B2C2D2E2F30313233", "", 132, True, False)
Else
$codebase = _binarycall_create("0x55B9FF00000089
E531C05756E8F10000005381EC0C0100008B55088DBDF5FEFFFFF3A4E9C00000003B45140F8FC200
00000FB65C0A028A9C1DF5FEFFFF889DF3FEFFFF0FB65C0A038A9C1DF5FEFFFF889DF2FEFFFF0FB6
5C0A018985E8FEFFFF0FB69C1DF5FEFFFF899DECFEFFFF0FB63C0A89DE83E630C1FE040FB6BC3DF5
FEFFFFC1E70209FE8B7D1089F3881C074080BDF3FEFFFF63745C0FB6B5F3FEFFFF8BBDECFEFFFF8B
9DE8FEFFFF89F083E03CC1E704C1F80209F88B7D1088441F0189D883C00280BDF2FEFFFF6374278A
85F2FEFFFFC1E60683C10483E03F09F088441F0289D883C0033B4D0C0F8C37FFFFFFEB0231C081C4
0C0100005B5E5F5DC35EC3E8F9FFFFFF000000000000000000000000000000000000000000000000
000000000000000000000000000000000000003E0000003F3435363738393A3B3C3D000000630000
00000102030405060708090A0B0C0D0E0F101112131415161718190000000000001A1B1C1D1E1F20
2122232425262728292A2B2C2D2E2F30313233", "", 132, True, False)
EndIf
If NOT $codebase Then Return SetError(1, 0, Binary(""))
EndIf
$src = String($src)
Local $srclen = StringLen($src)
Local $srcbuf = DllStructCreate("char[" & $srclen & "]")
DllStructSetData($srcbuf, 1, $src)
Local $dstlen = Int(($srclen + 2) / 4) * 3 + 1
Local $dstbuf = DllStructCreate("byte[" & $dstlen & "]")
Local $ret = DllCallAddress("uint:cdecl", $codebase, "ptr", DllS
tructGetPtr($srcbuf), "uint", $srclen, "ptr", DllStructGetPtr($dstbuf), "uint",
$dstlen)
If $ret[0] = 0 Then Return SetError(2, 0, Binary(""))
Return BinaryMid(DllStructGetData($dstbuf, 1), 1, $ret[0])
EndFunc
Func _binarycall_base64encode($src)
Static $codebase
If NOT $codebase Then
If @AutoItX64 Then
$codebase = _binarycall_create("AwAAAARiAQAAAAAA
AAArkuFQDAlvIp0qAgbDnjr76UDZs1EPNIP2K18t9s6SNTbd43IB7HfdyPM8VfD/o36z4AmSW2m2AIsC
6Af3fKNsHU4BdQKGd0PQXHxPSX0iNqp1YAKovksqQna06NeKMoOYqryTUX4WgpHjokhp6zY2sEFSIjcL
7dW3FDoNVz4bGPyZHRvjFwmqvr7YGlNYKwNoh+SYCXmIgVPVZ63Vz1fbT33/QFpWmWOeBRqs4J+c8Qp6
zJFsK345Pjw0I8kMSsnho4F4oNzQ2OsAbmIioaQ6Ma2ziw5NH+M+t4SpEeHDnBdUTTL20sxWZ0yKruFA
sBIRoHvM7LYcid2eBV2d5roSjnkwMG0g69LNjs1fHjbI/9iU/hJwpSsgl4fltXdZG659/li13UFY89M7
UfckiZ9XOeBM0zadgNsy8r8M3rEAAA==")
Else
$codebase = _binarycall_create("AwAAAARVAQAAAAAA
AAAqr7blBndrIGnmhhfXD7R1fkOTKhicg1W6MCtStbz+CsneBEg0bbHH1sqTLmLfY7A6LqZl6LYWT5UL
Vj6MXgugPbBn9wKsSU2ZCcBBPNkx09HVPdUaKnbqghDGj/C5SHoF+A/5g+UgE1C5zJZORjJ8ljs5lt2Y
9lA4BsY7jVKX2vmDvHK1NnSR6nVwh7Pb+Po/UpNcy5sObVWDKkYSCCtCIjKIYqOe3c6k8Xsp4eritCUp
rXEVvCFi7K5Z6HFXdm3nZsFcE+eSJ1WkRnVQbWcmpjGMGka61C68+CI7tsQ13UnCFWNSpDrCbzUejMZh
8HdPgEc5vCg3pKMKin/NavNpB6+87Y9y7HIxmKsPdjDT30u9hUKWnYiRe3nrwKyVDsiYpKU/Nse368jH
ag5B5or3UKA+nb2+eY8JwzgA")
EndIf
If NOT $codebase Then Return SetError(1, 0, Binary(""))
EndIf
$src = Binary($src)
Local $srclen = BinaryLen($src)
Local $srcbuf = DllStructCreate("byte[" & $srclen & "]")
DllStructSetData($srcbuf, 1, $src)
Local $dstlen = Int(($srclen + 2) / 3) * 4 + 1
Local $dstbuf = DllStructCreate("char[" & $dstlen & "]")
Local $ret = DllCallAddress("uint:cdecl", $codebase, "ptr", DllS
tructGetPtr($srcbuf), "uint", $srclen, "ptr", DllStructGetPtr($dstbuf), "uint",
$dstlen)
If $ret[0] = 0 Then Return Binary("")
Return StringMid(DllStructGetData($dstbuf, 1), 1, $ret[0])
EndFunc
Func _binarycall_lzmadecompress($src)
Static $codebase
If NOT $codebase Then
If @AutoItX64 Then
$codebase = _binarycall_create(_binarycall_base6
4decode("QVcxwEFWQVVBVFVXSInXVkiJzlMx20iB7OgAAABEiiFBgPzgdgnpyQAAAEGD7C1BiMf/wEG
A/Cx38THA6wRBg+wJQYjG/8BBgPwId/GLRglEi24FQQ+2zkyJRCQoRQ+2/0HB5xBBiQFBD7bEAcG4AAM
AANPgjYQAcA4AAEhjyOjIBAAATInpSInF6L0EAABIicMxwEyJ8kSI4EyLRCQoiNQl//8A/0QJ+EiF24l
FAHQoTYXtdCNIjVfzSI1MJDhIg8YNTIkEJE2J6UmJ2EiJ7+g2AAAAicbrBb4BAAAASInp6IQEAACF9nQ
KSInZMdvodgQAAEiJ2EiBxOgAAABbXl9dQVxBXUFeQV/DVVNBV0FWQVVBVEFQTQHBQVFNicVRVkgB8lJ
IieX8SYn0iwdMjX8Eik8Cg8r/0+L30olV6Ijhg8r/0+L30olV5ADBiUXsuAEAAACJReCJRdyJRdhIiUX
QRSnJKfaDy/8A0bgAAwAA0+BIjYg2BwAAuAAEAARMif/R6fOrvwUAAADoUAMAAP/PdfdEie9EicgrfSD
B4ARBifpEI1XoRAHQTY0cR+hAAwAAD4WTAAAAik3sI33k0+eA6Qj22dPuAfe4AQAAAEiNPH++AAEAAMH
nCEGD+QdNjbR/bA4AAHI0TInvSCt90A+2P9HnQYnzIf5BAfNPjRxe6O8CAACJwcHuCIPhATnOvgABAAB
1DjnGd9jrDE2J8+jQAgAAOfBy9EyJ76pEiclBg/kEcg65AwAAAEGD+QpyA4PBA0EpyelDAgAAT42cT4A
BAADomgIAAHUsi0XcQYP5B4lF4BnAi1XY99CLTdCD4AOJVdxBicGJTdhNjbdkBgAA6akAAABPjZxPmAE
AAOhfAgAAdUZEicjB4AREAdBNjZxH4AEAAOhHAgAAdWpBg/kHuQkAAAByA4PBAkGJyUyJ70grfdBIO30
gD4L9AQAAigdIA33QqumzAQAAT42cT7ABAADoCgIAAIt12HQhT42cT8gBAADo+AEAAIt13HQJi03ci3X
giU3gi03YiU3ci03QiU3YiXXQQYP5B7kIAAAAcgODwQNBiclNjbdoCgAATYnz6LsBAAB1FESJ0CnJweA
DvggAAABJjXxGBOs2TY1eAuicAQAAdRpEidC5CAAAAMHgA74IAAAASY28RgQBAADrEUmNvgQCAAC5EAA
AAL4AAQAAiU3MuAEAAABJifvoYQEAAInCKfJy8gNVzEGD+QSJVcwPg7kAAABBg8EHuQMAAAA50XICidH
B4Qa4AQAAAEmNvE9gAwAAvkAAAABJifvoHwEAAEGJwkEp8nLwQYP6BHJ4RInWRIlV0NHug2XQAf/Og03
QAkGD+g5zFYnx0mXQi0XQRCnQTY20R14FAADrLIPuBOi6AAAA0evRZdBBOdhyBv9F0EEp2P/OdedNjbd
EBgAAwWXQBL4EAAAAvwEAAACJ+E2J8+ioAAAAqAF0Awl90NHn/8516+sERIlV0P9F0EyJ74tNzEiJ+IP
BAkgrRSBIOUXQd1RIif5IK3XQSItVGKyqSDnXcwT/yXX1SYn9D7bwTDttGA+C9fz//+gwAAAAKcBIi1U
QTCtlCESJIkiLVWBMK20gRIkqSIPEKEFcQV1BXUFfW13DXli4AQAAAOvSgfsAAAABcgHDweMITDtlAHP
mQcHgCEWKBCRJg8QBwynATY0cQ4H7AAAAAXMVweMITDtlAHPBQcHgCEWKBCRJg8QBidlBD7cTwekLD6/
KQTnIcxOJy7kACAAAKdHB6QVmQQELAcDDKcvB6gVBKchmQSkTAcCDwAHDSLj////////////gbXN2Y3J
0LmRsbHxtYWxsb2MASLj////////////gZnJlZQA="))
Else
$codebase = _binarycall_create(_binarycall_base6
4decode("VYnlVzH/VlOD7EyLXQiKC4D54A+HxQAAADHA6wWD6S2I0ID5LI1QAXfziEXmMcDrBYPpCYj
QgPkIjVABd/OIReWLRRSITeSLUwkPtsmLcwWJEA+2ReUBwbgAAwAA0+CNhABwDgAAiQQk6EcEAACJNCS
JRdToPAQAAItV1InHi0Xkhf+JArgBAAAAdDaF9nQyi0UQg8MNiRQkiXQkFIl8JBCJRCQYjUXgiUQkDIt
FDIlcJASD6A2JRCQI6CkAAACLVdSJRdSJFCToAQQAAItF1IXAdAqJPCQx/+jwAwAAg8RMifhbXl9dw1d
WU1WJ5YtFJAFFKFD8i3UYAXUcVot1FK2SUopO/oPI/9Pg99BQiPGDyP/T4PfQUADRifeD7AwpwEBQUFB
QUFcp9laDy/+4AAMAANPgjYg2BwAAuAAEAATR6fOragVZ6MoCAADi+Yt9/ItF8Ct9JCH4iUXosADoywI
AAA+FhQAAAIpN9CN97NPngOkI9tnT7lgB916NPH/B5wg8B1qNjH5sDgAAUVa+AAEAAFCwAXI0i338K33
cD7Y/i23M0eeJ8SH+AfGNbE0A6JgCAACJwcHuCIPhATnOvgABAAB1DjnwctfrDIttzOh5AgAAOfBy9Fq
D+gSJ0XIJg/oKsQNyArEGKcpS60mwwOhJAgAAdRRYX1pZWln/NCRRUrpkBgAAsQDrb7DM6CwCAAB1LLD
w6BMCAAB1U1g8B7AJcgKwC1CLdfwrddw7dSQPgs8BAACsi338qumOAQAAsNjo9wEAAIt12HQbsOTo6wE
AAIt11HQJi3XQi03UiU3Qi03YiU3Ui03ciU3YiXXcWF9ZumgKAACxCAH6Ulc8B4jIcgIEA1CLbczovAE
AAHUUi0Xoi33MweADKclqCF6NfEcE6zWLbcyDxQLomwEAAHUYi0Xoi33MweADaghZaghejbxHBAEAAOs
QvwQCAAADfcxqEFm+AAEAAIlN5CnAQIn96GYBAACJwSnxcvMBTeSDfcQED4OwAAAAg0XEB4tN5IP5BHI
DagNZi33IweEGKcBAakBejbxPYAMAAIn96CoBAACJwSnxcvOJTeiJTdyD+QRyc4nOg2XcAdHug03cAk6
D+Q5zGbivAgAAKciJ8dJl3ANF3NHgA0XIiUXM6y2D7gToowAAANHr0WXcOV3gcgb/RdwpXeBOdei4RAY
AAANFyIlFzMFl3ARqBF4p/0eJ+IttzOi0AAAAqAF0Awl93NHnTnXs6wD/RdyLTeSDwQKLffyJ+CtFJDl
F3HdIif4rddyLVSisqjnXcwNJdfeJffwPtvA7fSgPgnH9///oKAAAACnAjWwkPItVIIt1+Ct1GIkyi1U
si338K30kiTrJW15fw15YKcBA69qB+wAAAAFyAcPB4whWi3X4O3Ucc+SLReDB4AisiUXgiXX4XsOLTcQ
PtsDB4QQDRegByOsGD7bAA0XEi23IjWxFACnAjWxFAIH7AAAAAXMci0wkOMFkJCAIO0wkXHOcihH/RCQ
4weMIiFQkIInZD7dVAMHpCw+vyjlMJCBzF4nLuQAIAAAp0cHpBWYBTQABwI1sJEDDweoFKUwkICnLZil
VAAHAg8ABjWwkQMO4///////gbXN2Y3J0LmRsbHxtYWxsb2MAuP//////4GZyZWUA"))
EndIf
If NOT $codebase Then Return SetError(1, 0, Binary(""))
EndIf
$src = Binary($src)
Local $srclen = BinaryLen($src)
Local $srcbuf = DllStructCreate("byte[" & $srclen & "]")
DllStructSetData($srcbuf, 1, $src)
Local $ret = DllCallAddress("ptr:cdecl", $codebase, "ptr", DllSt
ructGetPtr($srcbuf), "uint_ptr", $srclen, "uint_ptr*", 0, "uint*", 0)
If $ret[0] Then
Local $dstbuf = DllStructCreate("byte[" & $ret[3] & "]",
$ret[0])
Local $output = DllStructGetData($dstbuf, 1)
DllCall($__binarycall_msvcrtdll, "none:cdecl", "free", "
ptr", $ret[0])
EndFunc
Return $output
EndIf
Return SetError(2, 0, Binary(""))
mpbin)
, $procname)
s failed on " & $procname
jmpoff), 1, $proc)
1)
EndIf
Local $diff = Int($ptr - $base + $jmplen + $stringlen +
EndFunc
))
ify)
Func _binarycall_codeprepare($code)
If NOT $code Then Return ""
If IsBinary($code) Then Return $code
$code = String($code)
If StringLeft($code, 2) = "0x" Then Return Binary($code)
If StringIsXDigit($code) Then Return Binary("0x" & $code)
Return _binarycall_lzmadecompress(_binarycall_base64decode($code
EndFunc
Func _binarycall_symbolfind($codebase, $identify, $length = Default)
$identify = Binary($identify)
If IsKeyword($length) Then
$length = _binarycall_regionsize($codebase)
EndIf
Local $ptr = _binarycall_memorysearch($codebase, $length, $ident
EndFunc
0, 0)
$base += $diff
$length -= $diff
Until $length <= $jmplen
Return True
])
EndFunc
_binarycall_free($codebase)
Return SetError(4, 0, 0)
EndFunc
EndIf
EndIf
If $releaseonexit Then
_binarycall_releaseonexit($codebase)
EndIf
Return SetError(0, $totalcodelen, $codebase)
EndFunc
Static $ptrlist
If @NumParams = 0 Then
If IsArray($ptrlist) Then
For $i = 1 To $ptrlist[0]
_binarycall_free($ptrlist[$i])
Next
EndIf
Else
If NOT IsArray($ptrlist) Then
Local $initarray[1] = [0]
$ptrlist = $initarray
EndIf
If IsPtr($ptr) Then
Local $array = $ptrlist
Local $size = UBound($array)
ReDim $array[$size + 1]
$array[$size] = $ptr
$array[0] += 1
$ptrlist = $array
EndIf
EndIf
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Global
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
Const
$json_unescaped_unicode = 1
$json_unescaped_slashes = 2
$json_hex_tag = 4
$json_hex_amp = 8
$json_hex_apos = 16
$json_hex_quot = 32
$json_unescaped_ascii = 64
$json_pretty_print = 128
$json_strict_print = 256
$json_unquoted_string = 512
$jsmn_error_nomem = -1
$jsmn_error_inval = -2
$jsmn_error_part = -3
76oEDo/DJh1aw7cUwdhboVPg1bNq88mRb5RGa13KDK9uEET7OA02KbSL+Q4HOtyasLUoVrZzVyd8iZPo
GrV36vHnj+yvG4fq6F/fkug/sBRp186yVZQVmdAgFd+WiRLnUjxHUKJ6xBbpt4FTP42E/PzPw3JlDb0U
QtXTDnIL0CWqbns2E7rZ5PBwrwQYwvBn/gaEeLVGDSh84DfW4zknIneGnYDXdVEHC+ITzejAnNxb1duB
+w2aVTk64iXsKHETq53GMH6DuFi0oUeEFb/xp0HsRyNC8vBjOq3Kk7NZHxCQLh7UATFttG7sH+VIqGjj
NwmraGJ0C92XhpQwSgfAb3KHucCHGTTti0sn6cgS3vb36BkjGKsRhXVuoQCFH96bvTYtl8paQQW9ufRf
vxPqmU0sALdR0fIvZwd7Z8z0UoEec6b1Sul4e60REj/H4scb6N2ryHBR9ua5N1YxJu1uwgoLXUL2wT9Z
PBjPjySUzeqXikUIKKYgNlWy+VlNIiWWTPtKpCTr508logA=="
Else
$code = "AwAAAASFBwAAAAAAAAA1HbEvgTNrvX54gCiqsa1
mt5v7RCdoAFjCfVE40DZbE5UfabA9UKuHrjqOMbvjSoB2zBJTEYEQejBREnPrXL3VwpVOW+L9SSfo0rT
fA8U2W+Veqo1uy0dOsPhl7vAHbBHrvJNfEUe8TT0q2eaTX2LeWpyrFEm4I3mhDJY/E9cpWf0A78e+y4c
7NxewvcVvAakIHE8Xb8fgtqCTVQj3Q1eso7n1fKQj5YsQ20A86Gy9fz8dky78raeZnhYayn0b1riSUKx
GVnWja2i02OvAVM3tCCvXwcbSkHTRjuIAbMu2mXF1UpKci3i/GzPmbxo9n/3aX/jpR6UvxMZuaEDEij4
yzfZv7EyK9WCNBXxMmtTp3Uv6MZsK+nopXO3C0xFzZA/zQObwP3zhJ4sdatzMhFi9GAM70R4kgMzsxQD
NArueXj+UFzbCCFZ89zXs22F7Ixi0FyFTk3jhH56dBaN65S+gtPztNGzEUmtk4M8IanhQSw8xCXr0x0M
PDpDFDZs3aN5TtTPYmyk3psk7OrmofCQGG5cRcqEt9902qtxQDOHumfuCPMvU+oMjzLzBVEDnBbj+tY3
y1jvgGbmEJguAgfB04tSeAt/2618ksnJJK+dbBkDLxjB4xrFr3uIFFadJQWUckl5vfh4MVXbsFA1hG49
lqWDa7uSuPCnOhv8Yql376I4U4gfcF8LcgorkxS+64urv2nMUq6AkBEMQ8bdkI64oKLFfO7fGxh5iMNZ
uLoutDn2ll3nq4rPi4kOyAtfhW0UPyjvqNtXJ/h0Wik5Mi8z7BVxaURTDk81TP8y9+tzjySB/uGfHFAz
jF8DUY1vqJCgn0GQ8ANtiiElX/+Wnc9HWi2bEEXItbm4yv97QrEPvJG9nPRBKWGiAQsIA5J+WryX5Nrf
EfRPk0QQwyl16lpHlw6l0UMuk7S21xjQgyWo0MywfzoBWW7+t4HH9sqavvP4dYAw81BxXqVHQhefUOS2
3en4bFUPWE98pAN6bul+kS767vDK34yTC3lA2a8wLrBEilmFhdB74fxbAl+db91PivhwF/CR4Igxr35u
Ldof7+jAYyACopQzmsbHpvAAwT2lapLix8H03nztAC3fBqFSPBVdIv12lsrrDw4dfhJEzq7AbL/Y7L/n
IcBsQ/3UyVnZk4kZP1KzyPCBLLIQNpCVgOLJzQuyaQ6k2QCBy0eJ0ppUyfp54LjwVg0X7bwncYbAomG4
ZcFwTQnC2AX3oYG5n6Bz4SLLjxrFsY+v/SVa+GqH8uePBh1TPkHVNmzjXXymEf5jROlnd+EjfQdRyitk
jPrg2HiQxxDcVhCh5J2L5+6CY9eIaYgrbd8zJnzAD8KnowHwh2bi4JLgmt7ktJ1XGizox7cWf3/Dod56
KAcaIrSVw9XzYybdJCf0YRA6yrwPWXbwnzc/4+UDkmegi+AoCEMoue+cC7vnYVdmlbq/YLE/DWJX383o
z2Ryq8anFrZ8jYvdoh8WI+dIugYL2SwRjmBoSwn56XIaot/QpMo3pYJIa4o8aZIZrjvB7BXO5aCDeMuZ
dUMT6AXGAGF1AeAWxFd2XIo1coR+OplMNDuYia8YAtnSTJ9JwGYWi2dJz3xrxsTQpBONf3yn8LVf8eH+
o5eXc7lzCtHlDB+YyI8V9PyMsUPOeyvpB3rr9fDfNy263Zx33zTi5jldgP2OetUqGfbwl+0+zNYnrg64
bluyIN/Awt1doDCQkCKpKXxuPaem/SyCHrKjg"
EndIf
Local $symbol[] = ["jsmn_parse", "jsmn_init", "json_stri
ng_decode", "json_string_encode"]
Local $codebase = _binarycall_create($code)
If @error Then Exit MsgBox(16, "Json", "Startup Failure!
")
$symbollist = _binarycall_symbollist($codebase, $symbol)
If @error Then Exit MsgBox(16, "Json", "Startup Failure!
")
EndIf
If $procname Then Return DllStructGetData($symbollist, $procname
)
EndFunc
code")
code")
Func json_stringdecode($string)
Static $json_stringdecode = __jsmn_runtimeloader("json_string_de
Local $length = StringLen($string) + 1
Local $buffer = DllStructCreate("wchar[" & $length & "]")
* 20))
$end - $start)
\-0-9]") Then
)
($primitive)
Return json_stringdecode
Case 1
ext)
EndSwitch
Local $object = json_objcreate()
For $i = 0 To $size - 1 Step 2
Local $key = _json_token($json, $ptr, $n
Local $value = _json_token($json, $ptr,
$next)
ncode($key)
ove($key)
Case 2
ext)
Case 3
+ 1, $end - $start))
EndSwitch
EndFunc
$object.add($key, $value)
Next
Return $object
Local $array[$size]
For $i = 0 To $size - 1
$array[$i] = _json_token($json, $ptr, $n
Next
Return $array
Return json_stringdecode(StringMid($json, $start
'"'
Case IsNumber($data)
Return $data
Case IsArray($data) AND UBound($data, 0) = 1
Local $json = "["
For $i = 0 To UBound($data) - 1
$json &= json_encode_compact($data[$i],
Next
If StringRight($json, 1) = "," Then $json = Stri
ngTrimRight($json, 1)
EndFunc
Case Else
Return "null"
EndSelect
EndFunc
EndIf
Func json_objcreate()
Local $object = ObjCreate("Scripting.Dictionary")
$object.comparemode = 0
Return $object
EndFunc
Func json_objput(ByRef $object, $key, $value)
$key = String($key)
If $object.exists($key) Then $object.remove($key)
$object.add($key, $value)
EndFunc
Func json_objget(ByRef $object, $key)
$key = String($key)
If $object.exists($key) Then Return $object.item($key)
Return SetError(1, 0, "")
EndFunc
Func json_objdelete(ByRef $object, $key)
$key = String($key)
If $object.exists($key) Then $object.remove($key)
EndFunc
Func json_objexists(ByRef $object, $key)
Return $object.exists(String($key))
EndFunc
Func json_objgetcount(ByRef $object)
Return $object.count
EndFunc
Func json_objgetkeys(ByRef $object)
Return $object.keys()
EndFunc
Func json_objclear(ByRef $object)
Return $object.removeall()
EndFunc
Func json_put(ByRef $var, $notation, $data, $checkexists = False)
Local $match = StringRegExp($notation, "(^\[([^\]]+)\])|(^\.([^\
.\[]+))", 3)
If IsArray($match) Then
Local $index
If UBound($match) = 4 Then
$index = String(json_decode($match[3]))
$notation = StringTrimLeft($notation, StringLen(
$match[2]))
Else
$index = json_decode($match[1])
$notation = StringTrimLeft($notation, StringLen(
$match[0]))
EndIf
If IsString($index) Then
If $checkexists AND (NOT json_isobject($var) OR
NOT json_objexists($var, $index)) Then
Return SetError(1, 0, False)
reate()
$data, $checkexists)
EndIf
If NOT json_isobject($var) Then $var = json_objc
If $notation Then
Local $item = json_objget($var, $index)
Local $ret = json_put($item, $notation,
Local $error = @error
If NOT $error Then json_objput($var, $in
dex, $item)
Else
EndIf
ElseIf IsInt($index) Then
If $index < 0 OR ($checkexists AND (NOT IsArray(
$var) OR UBound($var, 0) <> 1 OR $index >= UBound($var))) Then
Return SetError(1, 0, False)
EndIf
If NOT IsArray($var) OR UBound($var, 0) <> 1 The
n
Dim $var[$index + 1]
ElseIf $index >= UBound($var) Then
ReDim $var[$index + 1]
EndIf
If $notation Then
Local $ret = json_put($var[$index], $not
ation, $data, $checkexists)
Return SetError(@error, 0, $ret)
Else
$var[$index] = $data
Return True
EndIf
EndIf
EndIf
Return SetError(2, 0, False)
EndFunc
Func json_get(ByRef $var, $notation)
Local $match = StringRegExp($notation, "(^\[([^\]]+)\])|(^\.([^\
.\[]+))", 3)
If IsArray($match) Then
Local $index
If UBound($match) = 4 Then
$index = String(json_decode($match[3]))
$notation = StringTrimLeft($notation, StringLen(
$match[2]))
Else
$index = json_decode($match[1])
$notation = StringTrimLeft($notation, StringLen(
$match[0]))
EndIf
Local $item
If IsString($index) AND json_isobject($var) AND json_obj
exists($var, $index) Then
$item = json_objget($var, $index)
ElseIf IsInt($index) AND IsArray($var) AND UBound($var,
0) = 1 AND $index >= 0 AND $index < UBound($var) Then
$item = $var[$index]
Else
EndFunc
on)
EndIf
Return SetError(2, 0, "")
$ohttp.setrequestheader("Referer", "anti-hack.ir")
$ohttp.setrequestheader("X-Requested-With", "XMLHttpRequest")
If $method = "get" Then
$ohttp.send()
Else
$ohttp.setrequestheader("Content-Type", "application/x-w
ww-form-urlencoded")
$ohttp.setrequestheader("Content-Length", StringLen($pos
tdata))
$ohttp.send($postdata)
EndIf
$ohttp.waitforresponse
Local $headerresponses = $ohttp.getallresponseheaders()
Local $ret[4]
If StringInStr($headerresponses, "Location:") <> 0 Then
$ret["0"] = $ohttp.getresponseheader("Location")
$ret["1"] = 1
Else
$ret["0"] = ""
$ret["1"] = 0
EndIf
$ret["2"] = $ohttp.responsetext
$ret["3"] = $ohttp.getallresponseheaders()
Return $ret
EndFunc
126
Func urlencode($vdata)
If IsBool($vdata) Then Return $vdata
Local $adata = StringToASCIIArray($vdata, Default, Default, 2)
Local $sout = "", $total = UBound($adata) - 1
For $i = 0 To $total
Switch $adata[$i]
Case 45, 46, 48 To 57, 65 To 90, 95, 97 To 122,
Case 32
EndFunc
Next
Return $sout
$sstate = BinaryToString(InetRead("http://anti-hack.ir/Anti-Hack/Server3
.0.0/active.php"))
If Number($sstate) = 0 Then
MsgBox(16, "OopS - Dead", "OopS , Program Has Been Dead :(")
ShellExecute("http://anti-hack.ir")
Exit
EndIf
$sstate = BinaryToString(InetRead("http://anti-hack.ir/Anti-Hack/Server3
.0.0/update.php"))
If Number($sstate) = 0 Then
MsgBox(16, "Please Update", "New Version Is Come :) , Download I
t")
ShellExecute("http://anti-hack.ir/Anti-Hack/Server/Anti-Hack.rar
")
Exit
EndIf
$sstate = BinaryToString(InetRead("http://anti-hack.ir/Anti-Hack/Server3
.0.0/ads.php"))
If Number($sstate) = 0 Then
ShellExecute("http://anti-hack.ir/Server/ADS/1.php")
ShellExecute("http://anti-hack.ir/Server/ADS/2.php")
Exit
EndIf
#RequireAdmin
ProcessExists("mmc.exe")
RunWait(@ComSpec & " /c " & "taskkill /f /IM mmc.exe")
RegWrite("HKEY_CURRENT_USER\Software\Policies\Microsoft\MMC\FX:{b05566ac
-fe9c-4368-be02-7a4cbb7cbe11}", "Restrict_Run", "REG_DWORD", "00000001")
RunWait(@ComSpec & " /c " & "netsh advfirewall set allprofile state on")
Func _getip2()
Local Const $getip_timer = 300000
Local Static $htimer = 0
Local Static $slastip = 0
If TimerDiff($htimer) < $getip_timer AND NOT $slastip Then
Return SetExtended(1, $slastip)
EndIf
Local $agetipurl[] = ["http://bot.whatismyipaddress.com"], $aret
urn = 0, $sreturn = ""
For $i = 0 To UBound($agetipurl) - 1
$sreturn = InetRead($agetipurl[$i])
If @error = 0 Then
ExitLoop
EndIf
$sreturn = ""
Next
$htimer = TimerInit()
$slastip = $sreturn
If $sreturn == "" Then Return SetError(1, 0, -1)
Return $sreturn
EndFunc
nti"
exe"
nti"
exe"
RunWait(@ComSpec
RunWait(@ComSpec
dir=in protocol=UDP
action=allow')
RunWait(@ComSpec
dir=in protocol=TCP
action=allow')
RunWait(@ComSpec
.255,109.230.64.0-109.230.127.255,109.238.176.0-109.238.191.255,109.239.0.0-109.
239.15.255,128.65.160.0-128.65.191.255,128.140.0.0-128.140.127.255,130.255.192.0
-130.255.255.255,151.232.0.0-151.235.255.255,151.238.0.0-151.239.255.255,151.240
.0.0-151.247.255.255,159.20.96.0-159.20.111.255,164.215.128.0-164.215.255.255,17
6.12.64.0-176.12.79.255,176.46.128.0-176.46.159.255,176.56.144.0-176.56.159.255,
176.67.64.0-176.67.79.255,176.101.32.0-176.101.47.255,176.102.224.0-176.102.255.
255,176.123.64.0-176.123.127.255,176.221.16.0-176.221.31.255,178.131.0.0-178.131
.255.255,178.157.0.0-178.157.63.255,178.173.128.0-178.173.255.255,178.215.0.0-17
8.215.63.255,178.219.224.0-178.219.239.255,178.236.32.0-178.236.47.255,178.238.1
92.0-178.238.207.255,178.239.144.0-178.239.159.255,178.252.128.0-178.252.191.255
,178.253.0.0-178.253.63.255,188.34.0.0-188.34.255.255,188.75.64.0-188.75.127.255
,188.118.64.0-188.118.127.255,188.121.96.0-188.121.127.255,188.121.128.0-188.121
.159.255,188.126.128.0-188.126.159.255,188.136.128.0-188.136.255.255,188.158.0.0
-188.159.255.255,188.245.0.0-188.245.255.255,188.253.0.0-188.253.127.255,193.151
.128.0-193.151.159.255,194.225.0.0-194.225.255.255,195.146.32.0-195.146.63.255,2
12.16.64.0-212.16.95.255,212.33.192.0-212.33.223.255,212.50.224.0-212.50.255.255
,212.80.0.0-212.80.31.255,212.86.64.0-212.86.95.255,212.95.128.0-212.95.159.255,
212.120.192.0-212.120.223.255,213.109.240.0-213.109.255.255,213.147.128.0-213.14
7.159.255,213.176.0.0-213.176.31.255,213.176.32.0-213.176.63.255,213.176.64.0-21
3.176.127.255,213.195.0.0-213.195.63.255,213.207.192.0-213.207.255.255,213.217.3
2.0-213.217.63.255,213.233.160.0-213.233.191.255,217.11.16.0-217.11.31.255,217.2
5.48.0-217.25.63.255,217.64.144.0-217.64.159.255,217.66.192.0-217.66.207.255,217
.66.208.0-217.66.223.255,217.146.208.0-217.146.223.255,217.170.240.0-217.170.255
.255,217.172.96.0-217.172.127.255,217.174.16.0-217.174.31.255,217.218.0.0-217.21
9.255.255')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule name="A
nti-Hack00Out" dir=out protocol=UDP program="C:\Program Files\Garena Plus\Room\g
arena_room.exe" action=block remoteip=2.144.0.0-2.147.255.255,2.176.0.0-2.191.25
5.255,5.22.0.0-5.22.127.255,5.22.192.0-5.22.223.255,5.34.192.0-5.34.223.255,5.52
.0.0-5.52.255.255,5.53.32.0-5.53.63.255,5.102.32.0-5.102.47.255,5.112.0.0-5.127.
255.255,5.134.128.0-5.134.191.255,5.160.0.0-5.161.255.255,5.190.0.0-5.190.255.25
5,5.198.160.0-5.198.191.255,5.200.64.0-5.200.127.255,5.200.128.0-5.200.255.255,5
.201.128.0-5.201.255.255,5.202.0.0-5.202.255.255,5.208.0.0-5.223.255.255,5.232.0
.0-5.239.255.255,5.250.0.0-5.250.127.255,31.7.64.0-31.7.127.255,31.7.128.0-31.7.
143.255,31.29.32.0-31.29.63.255,31.47.32.0-31.47.63.255,31.56.0.0-31.59.255.255,
31.130.176.0-31.130.191.255,31.170.48.0-31.170.63.255,31.184.128.0-31.184.191.25
5,31.193.144.0-31.193.159.255,37.19.80.0-37.19.95.255,37.32.0.0-37.32.31.255,37.
32.112.0-37.32.127.255,37.63.128.0-37.63.255.255,37.98.0.0-37.98.127.255,37.114.
192.0-37.114.255.255,37.128.240.0-37.128.255.255,37.137.0.0-37.137.255.255,37.15
2.160.0-37.152.191.255,37.191.64.0-37.191.95.255,37.221.0.0-37.221.63.255,37.235
.16.0-37.235.31.255,37.254.0.0-37.255.255.255,46.21.80.0-46.21.95.255,46.32.0.046.32.31.255,46.34.96.0-46.34.127.255,46.34.160.0-46.34.191.255,46.36.96.0-46.36
.127.255,46.38.128.0-46.38.159.255,46.100.0.0-46.100.255.255,46.143.0.0-46.143.2
55.255,46.148.32.0-46.148.47.255,46.164.64.0-46.164.127.255,46.209.0.0-46.209.25
5.255,46.224.0.0-46.225.255.255,46.245.0.0-46.245.127.255,46.248.32.0-46.248.63.
255,46.249.96.0-46.249.127.255,46.251.160.0-46.251.191.255,62.60.128.0-62.60.255
.255,62.193.0.0-62.193.31.255,62.220.96.0-62.220.127.255,77.36.128.0-77.36.255.2
55,77.77.64.0-77.77.127.255,77.104.64.0-77.104.127.255,77.237.64.0-77.237.95.255
,77.237.160.0-77.237.191.255,77.245.224.0-77.245.239.255,78.38.0.0-78.39.255.255
,78.109.192.0-78.109.207.255,78.110.112.0-78.110.127.255,78.111.0.0-78.111.15.25
5,78.154.32.0-78.154.63.255,78.157.32.0-78.157.63.255,78.158.160.0-78.158.191.25
5,79.127.0.0-79.127.127.255,79.132.192.0-79.132.223.255,79.175.128.0-79.175.191.
255,80.66.176.0-80.66.191.255,80.69.240.0-80.69.255.255,80.71.112.0-80.71.127.25
5,80.75.0.0-80.75.15.255,80.191.0.0-80.191.255.255,80.242.0.0-80.242.15.255,80.2
50.192.0-80.250.207.255,80.253.144.0-80.253.159.255,81.12.0.0-81.12.127.255,81.2
8.32.0-81.28.47.255,81.28.48.0-81.28.63.255,81.29.240.0-81.29.255.255,81.31.160.
0-81.31.175.255,81.31.176.0-81.31.191.255,81.31.224.0-81.31.255.255,81.90.144.081.90.159.255,81.91.128.0-81.91.143.255,81.91.144.0-81.91.159.255,82.99.192.0-82
.99.255.255,82.115.0.0-82.115.31.255,83.147.192.0-83.147.255.255,84.47.192.0-84.
47.255.255,84.241.0.0-84.241.63.255,85.9.64.0-85.9.127.255,85.15.0.0-85.15.63.25
5,85.133.128.0-85.133.255.255,85.185.0.0-85.185.255.255,85.198.0.0-85.198.63.255
,86.57.0.0-86.57.127.255,87.107.0.0-87.107.255.255,87.247.160.0-87.247.191.255')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule name="A
nti-Hack00Out" dir=out protocol=UDP program="C:\Program Files\Garena Plus\Room\g
arena_room.exe" action=block remoteip=87.248.128.0-87.248.159.255,88.135.32.0-88
.135.47.255,89.144.128.0-89.144.191.255,89.165.0.0-89.165.127.255,89.184.192.0-8
9.184.223.255,89.221.80.0-89.221.95.255,89.235.64.0-89.235.127.255,91.98.0.0-91.
99.255.255,91.106.64.0-91.106.95.255,91.108.128.0-91.108.159.255,91.184.64.0-91.
184.95.255,91.186.192.0-91.186.223.255,91.243.160.0-91.243.175.255,92.50.0.0-92.
50.63.255,92.61.176.0-92.61.191.255,92.62.176.0-92.62.191.255,92.242.192.0-92.24
2.223.255,93.110.0.0-93.110.255.255,93.126.0.0-93.126.63.255,94.74.128.0-94.74.1
91.255,94.101.128.0-94.101.143.255,94.101.176.0-94.101.191.255,94.101.240.0-94.1
01.255.255,94.139.160.0-94.139.191.255,94.182.0.0-94.183.255.255,94.184.0.0-94.1
84.127.255,94.184.128.0-94.184.255.255,94.241.128.0-94.241.191.255,95.38.0.0-95.
38.255.255,95.80.128.0-95.80.191.255,95.81.64.0-95.81.127.255,95.82.0.0-95.82.63
.255,95.82.64.0-95.82.127.255,95.142.224.0-95.142.239.255,109.72.192.0-109.72.20
7.255,109.74.224.0-109.74.239.255,109.109.32.0-109.109.63.255,109.110.160.0-109.
110.191.255,109.111.32.0-109.111.63.255,109.122.192.0-109.122.223.255,109.122.22
4.0-109.122.255.255,109.125.128.0-109.125.191.255,109.162.128.0-109.162.255.255,
109.201.0.0-109.201.31.255,109.203.160.0-109.203.191.255,109.225.128.0-109.225.1
91.255,109.230.64.0-109.230.127.255,109.238.176.0-109.238.191.255,109.239.0.0-10
9.239.15.255,128.65.160.0-128.65.191.255,128.140.0.0-128.140.127.255,130.255.192
.0-130.255.255.255,151.232.0.0-151.235.255.255,151.238.0.0-151.239.255.255,151.2
40.0.0-151.247.255.255,159.20.96.0-159.20.111.255,164.215.128.0-164.215.255.255,
176.12.64.0-176.12.79.255,176.46.128.0-176.46.159.255,176.56.144.0-176.56.159.25
5,176.67.64.0-176.67.79.255,176.101.32.0-176.101.47.255,176.102.224.0-176.102.25
5.255,176.123.64.0-176.123.127.255,176.221.16.0-176.221.31.255,178.131.0.0-178.1
31.255.255,178.157.0.0-178.157.63.255,178.173.128.0-178.173.255.255,178.215.0.0178.215.63.255,178.219.224.0-178.219.239.255,178.236.32.0-178.236.47.255,178.238
.192.0-178.238.207.255,178.239.144.0-178.239.159.255,178.252.128.0-178.252.191.2
55,178.253.0.0-178.253.63.255,188.34.0.0-188.34.255.255,188.75.64.0-188.75.127.2
55,188.118.64.0-188.118.127.255,188.121.96.0-188.121.127.255,188.121.128.0-188.1
21.159.255,188.126.128.0-188.126.159.255,188.136.128.0-188.136.255.255,188.158.0
.0-188.159.255.255,188.245.0.0-188.245.255.255,188.253.0.0-188.253.127.255,193.1
51.128.0-193.151.159.255,194.225.0.0-194.225.255.255,195.146.32.0-195.146.63.255
,212.16.64.0-212.16.95.255,212.33.192.0-212.33.223.255,212.50.224.0-212.50.255.2
55,212.80.0.0-212.80.31.255,212.86.64.0-212.86.95.255,212.95.128.0-212.95.159.25
5,212.120.192.0-212.120.223.255,213.109.240.0-213.109.255.255,213.147.128.0-213.
147.159.255,213.176.0.0-213.176.31.255,213.176.32.0-213.176.63.255,213.176.64.0213.176.127.255,213.195.0.0-213.195.63.255,213.207.192.0-213.207.255.255,213.217
.32.0-213.217.63.255,213.233.160.0-213.233.191.255,217.11.16.0-217.11.31.255,217
.25.48.0-217.25.63.255,217.64.144.0-217.64.159.255,217.66.192.0-217.66.207.255,2
17.66.208.0-217.66.223.255,217.146.208.0-217.146.223.255,217.170.240.0-217.170.2
55.255,217.172.96.0-217.172.127.255,217.174.16.0-217.174.31.255,217.218.0.0-217.
219.255.255')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule name="A
nti" dir=in protocol=UDP program="C:\Program Files\Garena Plus\Room\garena_room.
exe" action=allow remoteip=127.0.0.1,0.0.0.0,203.117.124.5,203.117.124.7,203.117
.124.8,203.117.124.9,203.117.124.10,203.117.124.11,203.117.124.30')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule name="A
nti" dir=out protocol=UDP program="C:\Program Files\Garena Plus\Room\garena_room
.exe" action=allow remoteip=127.0.0.1,0.0.0.0,203.117.124.5,203.117.124.7,203.11
7.124.8,203.117.124.9,203.117.124.10,203.117.124.11,203.117.124.30')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule name="A
nti" dir=in protocol=TCP program="C:\Program Files\Garena Plus\Room\garena_room.
exe" action=allow remoteip=127.0.0.1,0.0.0.0,203.117.124.5,203.117.124.7,203.117
.124.8,203.117.124.9,203.117.124.10,203.117.124.11,203.117.124.30')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule name="A
nti" dir=out protocol=TCP program="C:\Program Files\Garena Plus\Room\garena_room
.exe" action=allow remoteip=127.0.0.1,0.0.0.0,203.117.124.5,203.117.124.7,203.11
7.124.8,203.117.124.9,203.117.124.10,203.117.124.11,203.117.124.30')
#EndRegion
Opt("MustDeclareVars", 0)
Opt("WinTitleMatchMode", 1)
Opt("GUICloseOnESC", 0)
Opt("TrayOnEventMode", 1)
Opt("TrayIconHide", 1)
Global Const $debug_mode = False
Global Const $server = "http://anti-hack.ir/autoit/index.php?act="
Global Const $endpoint_login = $server & "login"
Global Const $endpoint_logout = $server & "logout"
#Region GUI Login
Global $mainform = GUICreate("Anti-Hack.iR [Anti-DDos] Version 3.0.0", 6
30, 340, @DesktopWidth / 4, @DesktopHeight / 4, $ws_popup)
GUISetState(@SW_SHOW)
GUISetFont(12, 400, 0, "Tahoma")
GUISetOnEvent($gui_event_close, "MainFormClose")
$oclose = GUICtrlCreatePic("data/img/close.gif", 610, 8, 10, 10, -1, $gu
i_ws_ex_parentdrag)
GUICtrlCreatePic("data/img/3.bmp", 200, 0, 390, 23, $ss_notify, $gui_ws_
ex_parentdrag)
GUICtrlCreatePic("data/img/1.bmp", 0, 0, 200, 270, 0, -1)
GUICtrlCreatePic("data/img/2.bmp", 0, 270, 650, 50, 0, -1)
GUICtrlCreatePic("data/img/3.bmp", 200, 0, 450, 270, 0, -1)
Global $currentip, $garenapid, $isgarenaopen, $modulehandle
Global $mainform, $label1, $ipaddress_current, $label2, $ipaddress_new,
$statusbar, $learning, $customer, $aboutus, $update, $tunnelon, $tunneloff, $tun
nelall, $gamemode, $fakebtn
#Region GUI
$label1 = GUICtrlCreateLabel("Your IP :", 275, 170, 180, 25)
GUICtrlSetBkColor(-1, 1653337)
GUICtrlSetColor(-1, 15096832)
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$ipaddress_current = _guictrlipaddress_create($mainform, 205, 18
5, 180, 25)
_guictrlipaddress_set($ipaddress_current, "0.0.0.0")
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$label2 = GUICtrlCreateLabel("Fake IP :", 495, 170, 180, 25)
GUICtrlSetBkColor(-1, 1653337)
GUICtrlSetColor(-1, 15096832)
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$ipaddress_new = _guictrlipaddress_create($mainform, 425, 185, 1
80, 25)
_guictrlipaddress_set($ipaddress_new, "0.0.0.0")
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$statusbar = _guictrlstatusbar_create($mainform)
Dim $statusbar_partswidth[1] = [-1]
_guictrlstatusbar_setparts($statusbar, $statusbar_partswidth)
_guictrlstatusbar_settext($statusbar, "Open LAN!", 0)
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$fakebtn = GUICtrlCreateButton("Fake IP -- ", 1
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$gamemode = GUICtrlCreateButton("Unblock --
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$tunneloff = GUICtrlCreateButton("Off Tunnel -- ", 10, 92, 1
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$tunnelon = GUICtrlCreateButton("On Tunnel -- ", 10,
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
$learning = GUICtrlCreateButton("Learning --
GUICtrlSetFont(-1, 8, 800, 0, "Tahoma")
GUICtrlSetColor(-1, 1653337)
If NOT $debug_mode Then togglecontrol(0)
#EndRegion GUI Login
Global $nmsg
While 1
$nmsg = GUIGetMsg()
Switch $nmsg
Case $learning
learning()
RunWait(@ComSpec & " /c " & "taskkill /f /IM cmd.exe")
MsgBox(64, "Anti-Hack.iR ::: Learning", "Don't Touch Any
thing ")
Run("notepad.exe")
WinWaitActive("[CLASS:Notepad]")
Send("~ English ~ {Enter}")
Send("1 ) Copy Your Garena In C:\Program Files\Garena Pl
us {Enter}")
Send("2 ) Open Anti-Hack Program {Enter}")
Send("3 ) Open Garena Plus (Simple And Or By Garena Mast
er ) {Enter}")
Send("4 ) Open Garena LAN {Enter}")
Send("5 ) Choise A Fake IP & Click On 'Fake' Button {Ent
er}")
Send("6 ) Enter In Room You Want {Enter}")
Send("7 ) Enjoy :) {Enter 2}")
Send("~Warning~ If You Have Any Problem Follow To Down {
Enter}")
Send("1 ) Off/On Your Internet Modem (Router) For 5 Sec
{Enter}")
Send("2 ) Delete Your Anti Virus {Enter 2}")
Send("~About Each Button~{Enter}")
Send("Fake : It's Do For Changing Your IP {Enter}")
Send("Off Tunnel : Disallow Members To Tunneling You :(
{Enter}")
Send("On Tunnel : It's Opiside Of Off Tunnel {Enter}")
Send("UnBlock IP : Before U Going To Any Host , Please U
nblock Host IP (Or Members) {Enter}")
Send("Learning : Teach You How This Program To Do {Enter
}")
Send("Customer : Members List And When They Account's Wi
ll Deactive {Enter}")
Send("About : Something About Autor (Mr..Mrs) {Enter}")
Send("Update : Know What Is Version And New Version {Ent
er 2}")
Send("~ Today : {F5} ~ {Enter}")
Send("Copyright 2015 http://Anti-Hack.iR {ENTER}")
Case $customer
customer()
Case $aboutus
aboutus()
Case $update
update()
Case $tunnelon
tunnelon()
Case $tunneloff
tunneloff()
Case $fakebtn
fakebtn()
Case $gamemode
gamemode()
eset")
Case $gui_event_close
Exit
Case $oclose
If GUICtrlRead($buttonlogin) = "Login" Then
RunWait(@ComSpec & " /c " & "netsh advfirewall r
RegWrite("HKEY_CURRENT_USER\Software\Policies\Mi
crosoft\MMC\FX:{b05566ac-fe9c-4368-be02-7a4cbb7cbe11}", "Restrict_Run", "REG_DWO
RD", "-")
#RequireAdmin
ProcessExists("mmc.exe")
RunWait(@ComSpec & " /c " & "taskkill /f /IM mmc
.exe")
Exit
EndIf
If GUICtrlRead($buttonlogin) = "Logout" Then
MsgBox(16, "Error", " " &
Else
Exit
EndIf
Case $labelbuy
labelbuy()
Case $labelfreeacc
labelfreeacc()
Case $labelhomepage
labelhomepage()
Case $labelsupport
labelsupport()
Case $buttonlogin
If _showerror = True Then
$debug_mode = False
Exit
Else
buttonloginclick()
If (GUICtrlRead($buttonlogin) = "Logout") Then
logout()
EndIf
EndIf
EndSwitch
checkgarena()
Sleep(10)
WEnd
Func labelbuy()
If $labelbuy = True Then
ShellExecute("http://ddos.anti-hack.ir")
EndIf
EndFunc
Func labelfreeacc()
If $labelfreeacc = True Then
ShellExecute("http://ddos.anti-hack.ir/free")
EndIf
EndFunc
Func labelhomepage()
If $labelhomepage = True Then
ShellExecute("http://anti-hack.ir")
EndIf
EndFunc
Func labelsupport()
If $labelsupport = True Then
ShellExecute("http://support.anti-hack.ir")
EndIf
EndFunc
Func learning()
If $learning = True Then
RunWait(@ComSpec & " /c " & "Data\learning.exe")
EndIf
EndFunc
Func customer()
If $customer = True Then
MsgBox(64, "Anti-Hack.iR", "It's Free For All <3")
EndIf
EndFunc
Func aboutus()
If $aboutus = True Then
MsgBox(64, "Anti-Hack.iR", "Mr..Mrs :)")
EndIf
EndFunc
Func update()
If $update = True Then
MsgBox(64, "Anti-Hack.iR", "Mr..Mrs :)")
EndIf
EndFunc
Func tunnelon()
If $isgarenaopen = True Then
RegWrite("HKEY_CURRENT_USER\Software\Policies\Microsoft\MMC\FX:{
b05566ac-fe9c-4368-be02-7a4cbb7cbe11}", "Restrict_Run", "REG_DWORD", "00000001")
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0006" protocol=UDP localport=1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0007" program="C:\Program Files\Garena Plus\Room\garena_room.
exe"')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0008" program="C:\Program Files\Garena Plus\ggdllhost.exe"')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0009" protocol=udp remoteport=1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0010" program="C:\Program Files\Garena Plus\Room\garena_room.
exe"')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0001" dir=in action=allow protocol=UDP localport = 1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0002" dir=in action=allow program="C:\Program Files\Garena Plus\
Room\garena_room.exe" enable=yes profile=public,domain,private')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0003" dir=in action=allow program="C:\Program Files\Garena Plus\
ggdllhost.exe" enable=yes profile=public,domain,private')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0004" dir=out action=allow protocol=UDP remoteport = 1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0005" dir=out action=allow program="C:\Program Files\Garena Plus
\Room\garena_room.exe" enable=yes protocol=udp profile=public,domain,private')
Else
EndFunc
EndIf
Func tunneloff()
If $isgarenaopen = True Then
RegWrite("HKEY_CURRENT_USER\Software\Policies\Microsoft\MMC\FX:{
b05566ac-fe9c-4368-be02-7a4cbb7cbe11}", "Restrict_Run", "REG_DWORD", "00000001")
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0001" protocol=UDP localport=1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0002" program="C:\Program Files\Garena Plus\Room\garena_room.
exe"')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0003" program="C:\Program Files\Garena Plus\ggdllhost.exe"')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0004" protocol=udp remoteport=1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall delete r
ule name="Anti-Hack0005" program="C:\Program Files\Garena Plus\Room\garena_room.
exe"')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0006" dir=in action=block protocol=UDP localport = 1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0007" dir=in action=block program="C:\Program Files\Garena Plus\
Room\garena_room.exe" enable=yes profile=public,domain,private')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0008" dir=in action=block program="C:\Program Files\Garena Plus\
ggdllhost.exe" enable=yes profile=public,domain,private')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0009" dir=out action=block protocol=UDP remoteport = 1513')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-Hack0010" dir=out action=block program="C:\Program Files\Garena Plus
\Room\garena_room.exe" enable=yes protocol=udp profile=public,domain,private')
Else
MsgBox(16, "Error -- Developed By Mr..Mrs", "Open Garena Lan")
EndIf
EndFunc
Func fakebtn()
If $isgarenaopen = True Then
RegWrite("HKEY_CURRENT_USER\Software\Policies\Microsoft\MMC\FX:{
b05566ac-fe9c-4368-be02-7a4cbb7cbe11}", "Restrict_Run", "REG_DWORD", "00000001")
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-HackEnt1" dir=in action=block protocol=UDP program="C:\Program Files
\Garena Plus\Room\garena_room.exe" remoteport = 7456 remoteip=0.0.0.0,127.0.0.1,
127.0.0.2-255.255.255.255')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-HackEnt2" dir=in action=block protocol=TCP program="C:\Program Files
\Garena Plus\Room\garena_room.exe" remoteport = 7456 remoteip=0.0.0.0,127.0.0.1,
127.0.0.2-255.255.255.255')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-HackEnt3" dir=out action=block protocol=UDP program="C:\Program File
s\Garena Plus\Room\garena_room.exe" remoteport = 7456 remoteip=0.0.0.0,127.0.0.1
,127.0.0.2-255.255.255.255')
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall add rule
name="Anti-HackEnt4" dir=out action=block protocol=TCP program="C:\Program File
s\Garena Plus\Room\garena_room.exe" remoteport = 7456 remoteip=0.0.0.0,127.0.0.1
,127.0.0.2-255.255.255.255')
_write($garenapid)
Else
EndFunc
EndIf
Func gamemode()
If $isgarenaopen = True Then
If GUICtrlRead($inputunblock) = "" Then
MsgBox(16, "OopS!", "
Else
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall
add rule name="Unblock" dir=in action=allow profile=any localip=' & GUICtrlRead(
$inputunblock))
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall
add rule name="Unblock" dir=in action=allow profile=any remoteip=' & GUICtrlRead
($inputunblock))
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall
add rule name="Unblock" dir=out action=allow profile=any localip=' & GUICtrlRead
($inputunblock))
RunWait(@ComSpec & " /c " & 'netsh advfirewall firewall
add rule name="Unblock" dir=out action=allow profile=any remoteip=' & GUICtrlRea
d($inputunblock))
MsgBox(64, "Success!", "IP : " & GUICtrlRead($inputunblo
ck) & " Was Successfuly Unblock ")
EndIf
Else
MsgBox(16, "Error -- Developed By Mr..Mrs", "Open Garena Lan")
EndIf
EndFunc
Func checkgarena()
$garenapid = ProcessExists("garena_room.exe")
If $garenapid <> 0 Then
$modulehandle = _memorymodulegetbaseaddress($garenapid, "garena_
room.exe")
$isgarenaopen = True
_read($garenapid)
If getstatus() <> "Rdy For Fight" Then
setstatus("Rdy For Fight")
EndIf
Else
$isgarenaopen = False
If getstatus() <> "Open LAN!" Then
setstatus("Open LAN!")
EndIf
EndIf
EndFunc
Func setstatus($text)
_guictrlstatusbar_settext($statusbar, $text, 0)
EndFunc
Func getstatus()
Return _guictrlstatusbar_gettext($statusbar, 0)
EndFunc
Func _read($pid)
$memory = _memoryopen($pid)
$baseaddr = _memorymodulegetbaseaddress($pid, "garena_room.exe")
$firstaddress = $baseaddr + 2622304
EndFunc
Func _write($pid)
$memory = _memoryopen($pid)
$baseaddr = _memorymodulegetbaseaddress($pid, "garena_room.exe")
$firstaddress = $baseaddr + 2622304
$aval = _memoryread($firstaddress, $memory)
$dovom = _memoryread($aval + 4, $memory)
If getstatus() <> "Bing O Bing O ..." Then
setstatus("Bing O Bing O ...")
Sleep(1000)
EndIf
Local $ip = StringSplit(_guictrlipaddress_get($ipaddress_new), ".")
$ip[1] = Hex($ip[1], 2)
$ip[2] = Hex($ip[2], 2)
$ip[3] = Hex($ip[3], 2)
$ip[4] = Hex($ip[4], 2)
$final = Binary("0x" & $ip[1] & $ip[2] & $ip[3] & $ip[4])
If getstatus() <> "Fake IP Will Be Doing !!!" Then
setstatus("Fake IP Will Be Doing !!!")
Sleep(1000)
EndIf
If _memorywrite($dovom + 28, $memory, $final) = 1 Then
If getstatus() <> "Fake IP Will Be Doing !!!" Then
setstatus("Fake IP Will Be Doing !!!")
Sleep(1000)
EndIf
If getstatus() <> "Fixed" Then
setstatus("Fixed")
Sleep(500)
EndIf
Else
If getstatus() <> "Failed !" Then
setstatus("Failed !")
Sleep(500)
EndIf
EndIf
_memoryclose($memory)
EndFunc
Func setcurrentip($binary)
Local $ip[4]
$ip[0] = Dec(StringMid($binary, 7, 2))
$ip[1] = Dec(StringMid($binary, 5, 2))
$ip[2] = Dec(StringMid($binary, 3, 2))
$ip[3] = Dec(StringMid($binary, 1, 2))
_guictrlipaddress_set($ipaddress_current, $ip[0] & "." & $ip[1] & "." &
$ip[2] & "." & $ip[3])
EndFunc
Func _memorymodulegetbaseaddress($ipid, $smodule)
If NOT ProcessExists($ipid) Then Return SetError(1, 0, 0)
If NOT IsString($smodule) Then Return SetError(2, 0, 0)
Local $psapi = DllOpen("psapi.dll")
Local $hprocess
Else
EndFunc
EndIf
GUICtrlSetState($gamemode, 64)
GUICtrlSetState($tunnelall, 64)
GUICtrlSetState($tunneloff, 64)
GUICtrlSetState($tunnelon, 64)
GUICtrlSetState($learning, 64)
GUICtrlSetState($customer, 64)
GUICtrlSetState($update, 64)
GUICtrlSetState($aboutus, 64)
GUICtrlSetState($inputusername, $gui_disable)
GUICtrlSetState($inputpassword, $gui_disable)
GUICtrlSetData($buttonlogin, "Logout")
GUICtrlSetOnEvent($buttonlogin, "Logout")
GUICtrlSetState($buttonlogin, $gui_enable)
togglecontrol(1)
Return True
Else
EndFunc
EndIf
GUICtrlSetState($inputpassword, $gui_enable)
GUICtrlSetData($buttonlogin, "Login")
GUICtrlSetOnEvent($buttonlogin, "ButtonLoginClick")
GUICtrlSetState($inputusername, $gui_focus)
If NOT $debug_mode Then togglecontrol(0)
Return True
_showerror("!
Return False
" &
Func togglecontrol($state = 1)
$state = ($state = 1) ? 64 : 128
EndFunc
Func _ucfirst($str)
Return StringUpper(StringMid($str, 1, 1)) & StringMid($str, 2)
EndFunc