parent
922b9dc022
commit
55f110df48
|
|
@ -1611,7 +1611,8 @@ type tdirviewer = class(tcustomcontrol)
|
|||
fms[i] := mi;
|
||||
end
|
||||
ftree.onrclick :=function(o,e)begin
|
||||
nd := o.CurrentNode;
|
||||
//nd := o.CurrentNode;
|
||||
nd := FTree.GetItemByYPos(e.ypos) ;
|
||||
if nd then
|
||||
begin
|
||||
if (nd.parent = o.rootnode) then //¸ùĿ¼
|
||||
|
|
|
|||
|
|
@ -74,6 +74,8 @@ type tapplication=class(tcomponent)
|
|||
Fmainform; //Ö÷´°¿Ú
|
||||
FDebug;
|
||||
Foldforminfo;
|
||||
FTerminated;
|
||||
static frundeep;
|
||||
function SetVisible(v);
|
||||
begin
|
||||
FVisible := v?true:false;
|
||||
|
|
@ -124,7 +126,9 @@ type tapplication=class(tcomponent)
|
|||
function create(AOwner);override;
|
||||
begin
|
||||
inherited;
|
||||
FTerminated := false;
|
||||
FVisible := false;
|
||||
frundeep := new tnumindexarray();
|
||||
end
|
||||
function WMACTIVATEAPP(o,e);virtual;
|
||||
begin
|
||||
|
|
@ -214,7 +218,11 @@ type tapplication=class(tcomponent)
|
|||
**}
|
||||
initialize();
|
||||
{$ifdef linuxgtk}
|
||||
return _wapi.gtk_mainidle();
|
||||
idledata := 123123+frundeep.length();
|
||||
frundeep.Push(idledata);
|
||||
r := _wapi.gtk_mainidle(idledata);
|
||||
frundeep.pop();
|
||||
return r;
|
||||
{$endif}
|
||||
if not FMessageObj then FMessageObj := new TTagMSG();
|
||||
ptr := FMessageObj._getptr_;
|
||||
|
|
@ -235,7 +243,8 @@ type tapplication=class(tcomponent)
|
|||
begin
|
||||
if FMessageObj.message=0x12 then
|
||||
begin
|
||||
return 1;
|
||||
//return 1;
|
||||
FTerminated := true;
|
||||
end else
|
||||
begin
|
||||
_wapi.TranslateMessage(ptr);
|
||||
|
|
@ -247,6 +256,7 @@ type tapplication=class(tcomponent)
|
|||
RunWorkerThreadLoop();
|
||||
_wapi.WaitMessage();
|
||||
end
|
||||
if FTerminated then break;
|
||||
|
||||
end
|
||||
{while (_wapi.GetMessageA(ptr, 0, 0, 0)) do
|
||||
|
|
|
|||
|
|
@ -3329,19 +3329,13 @@ type tgtkapis = class() //gtk
|
|||
////////////////////////// start ////////////////////////////////////////
|
||||
procedure gtk_init(argc:string;argcv:string);cdecl;external 'libgtk-3.so';
|
||||
procedure gtk_main ();cdecl;external 'libgtk-3.so';
|
||||
function gtk_mainidle();
|
||||
begin
|
||||
|
||||
idledata :=(new tcbytearray(4))._getptr_();
|
||||
function gtk_mainidle(idledata);
|
||||
begin
|
||||
//idledata :=(new tcbytearray(4))._getptr_();
|
||||
id := g_idle_add(gettslvcleventhandler_("tsl_gtk_idle"),idledata);
|
||||
gtk_main();
|
||||
g_idle_remove_by_data(idledata); //ɾ³ýidle
|
||||
return 1;
|
||||
idledata :=(new tcbytearray(4))._getptr_();
|
||||
id := tsl_gtk_idle_interface(idledata);//_wapi.tsl_gtk_idle_interface(idledata); //¹¹Ôìidle
|
||||
_wapi.gtk_main();
|
||||
_Wapi.g_idle_remove_by_data(idledata); //ɾ³ýidle
|
||||
return 1;
|
||||
end
|
||||
function g_idle_add(f:pointer;d:pointer):integer;cdecl;external 'libgtk-3.so';
|
||||
procedure gtk_main_quit();cdecl;external 'libgtk-3.so';
|
||||
|
|
|
|||
Loading…
Reference in New Issue