From 94e30f2af42e940e86ed59d6d108061e19c28d57 Mon Sep 17 00:00:00 2001 From: "Kirill Lipatov (Leency)" Date: Thu, 8 Dec 2016 17:20:55 +0000 Subject: [PATCH] cmm: various updates git-svn-id: svn://kolibrios.org@6791 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/cmm/eolite/include/copy.h | 2 +- programs/cmm/lib/clipboard.h | 6 +-- programs/cmm/lib/keyboard.h | 5 +++ programs/cmm/lib/kolibri.h | 67 ++++++++++++++++++++++++------ programs/cmm/lib/strings.h | 1 + programs/cmm/notify/notify.c | 2 +- 6 files changed, 65 insertions(+), 18 deletions(-) diff --git a/programs/cmm/eolite/include/copy.h b/programs/cmm/eolite/include/copy.h index 3d0689420e..85e8ce1ce8 100644 --- a/programs/cmm/eolite/include/copy.h +++ b/programs/cmm/eolite/include/copy.h @@ -42,7 +42,7 @@ void Copy(dword pcth, char cut) size_buf += 20; buff_data = malloc(size_buf); ESDWORD[buff_data] = size_buf; - ESDWORD[buff_data+4] = 3; + ESDWORD[buff_data+4] = SLOT_DATA_TYPE_RAW; ESINT[buff_data+8] = selected_count; copy_buf_offset = buff_data + 10; for (i=0; i20000) z1=0; else if(z1>screen.width-Form.width-10)z1=screen.width-Form.width; + if(z2<=10) || (z2>20000) z2=0; else if(z2>screen.height-Form.height-10)z2=screen.height-Form.height; + MoveSize(z1 , z2, OLD, OLD); + draw_window(); + } + pause(1); + } while (mouse.lkm); +} + +:void DefineHiddenButton(dword _x, _y, _w, _h, _id) +{ + DefineButton(_x, _y, _w, _h, _id + BT_HIDE, 0); +} + inline fastcall void DeleteButton( EDX) { EAX = 8; @@ -601,7 +642,7 @@ char __BUF_DIR__[4096]; dword path; } self; -dword __generator; // random number generator - äëÿ ãåíåðàöèè ñëó÷àéíûõ ÷èñåë +dword __generator; // random number generator - äëÿ ãåíåðàöèè ñëó÷àéíûõ ÷èñåë :dword program_path_length; diff --git a/programs/cmm/lib/strings.h b/programs/cmm/lib/strings.h index a7768b6648..774152a780 100644 --- a/programs/cmm/lib/strings.h +++ b/programs/cmm/lib/strings.h @@ -794,6 +794,7 @@ inline signed csshexdec(dword text) inline cdecl int sprintf(dword buf, format,...) { + #define END_ARGS 0xFF00FF //ARGS FUNCTION byte s; char X[10]; dword ret, tmp, l; diff --git a/programs/cmm/notify/notify.c b/programs/cmm/notify/notify.c index dc130d548d..30f4c72c01 100644 --- a/programs/cmm/notify/notify.c +++ b/programs/cmm/notify/notify.c @@ -116,7 +116,7 @@ void main() TEXT_Y = WIN_SIZE_Y/2-4; //emulate multithread :) - while (GetPixelColor(SCREEN_SIZE_X-1, SCREEN_SIZE_X, WIN_Y)==0x333333) WIN_Y+=WIN_SIZE_Y+17; + while (GetPixelColorFromScreen(SCREEN_SIZE_X-1, WIN_Y)==0x333333) WIN_Y+=WIN_SIZE_Y+17; shadow_buf_24 = malloc(WIN_SIZE_X*WIN_SIZE_Y*3); shadow_buf_32 = malloc(WIN_SIZE_X*WIN_SIZE_Y*4+8);