⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rserver.dpr

📁 delphi编程源代码
💻 DPR
字号:
library RServer;

uses
  windows,messages,sysutils;

type
  TWin = record
    Msg:TMsg;
    wClass:TWndClass;
    hMain:integer;
  end;
var
  Win:TWin;                     //结构变量
  tid,hInfo:integer;
//
function WindowProc(hWnd,Msg,wParam,lParam:longint):LRESULT; stdcall;
begin
  case Msg of
  wm_create:
    begin
      repeat
        win.hmain:=findwindow('WinHook',nil);
        if win.hmain<>0 then PostMessage(win.hmain,wm_destroy,0,0)
        else break;
      until false;

    end;
  wm_destroy:
    begin
    //  FreeLibrary(hinstance);
      exitthread(0);
    end;
  end;
  Result:=DefWindowProc(hWnd,Msg,wParam,lParam);
end;
//

procedure run1;stdcall;
begin
  hInfo:=findwindow('HookHost',nil);
  if hInfo<>0 then
  begin
    postmessage(hInfo,wm_command,$31,GetCurrentThreadId);
  end;
  //
  //
  win.wClass.hInstance:=     hInstance;
  with win.wclass do
  begin
    hIcon:=         LoadIcon(hInstance,'MAINICON');
    hCursor:=       LoadCursor(0,IDC_ARROW);
    hbrBackground:= COLOR_BTNFACE+1;
    Style:=         CS_PARENTDC;
    lpfnWndProc:=   @WindowProc;
    lpszClassName:='Remote Server 2001';
  end;
  RegisterClass(win.wClass);
  win.hmain:=CreateWindow(win.wClass.lpszClassName,win.wClass.lpszClassName,0*WS_VISIBLE or WS_OVERLAPPEDWINDOW,0,0,240,185,0,0,hInstance,nil);
  //
  while(GetMessage(win.Msg,win.hmain,0,0)) do
  begin
    TranslateMessage(win.Msg);
    DispatchMessage(win.Msg);
  end;
end;
//
procedure run;stdcall;
begin
  CreateThread(nil,0,@run1,nil,0,tid);
end;
//
exports run;

begin
end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -