aboutsummaryrefslogtreecommitdiffstats
path: root/lib/observer/src/observer_pro_wx.erl
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2012-05-09 14:42:09 +0200
committerDan Gudmundsson <[email protected]>2012-05-09 14:42:09 +0200
commit04745e3fbb5fe194bc7561f96300d821e7f9e2aa (patch)
treed0108a23fda15d664f85b0dd7eb307a0c9400d2b /lib/observer/src/observer_pro_wx.erl
parent75dbcf3ce8cb63dea0d674b67cb5d3d64d250e2a (diff)
parent5628fb8d88f91b3ef8e140e2658a6f61b4e42adb (diff)
downloadotp-04745e3fbb5fe194bc7561f96300d821e7f9e2aa.tar.gz
otp-04745e3fbb5fe194bc7561f96300d821e7f9e2aa.tar.bz2
otp-04745e3fbb5fe194bc7561f96300d821e7f9e2aa.zip
Merge branch 'dgud/observer/bug-fixes/OTP-10075' into maint
* dgud/observer/bug-fixes/OTP-10075: [observer] Add more popup menus and info selected pid [observer] Fix scrollbars in app-viewer [observer] Allow bifs when selecting functions for trace [observer] Fix gui-crash when table_copies couldn't be spawned [observer] Fix dead processes [observer] Ask epmd for local nodes [observer] Remove appmon ref when node goes down
Diffstat (limited to 'lib/observer/src/observer_pro_wx.erl')
-rw-r--r--lib/observer/src/observer_pro_wx.erl21
1 files changed, 14 insertions, 7 deletions
diff --git a/lib/observer/src/observer_pro_wx.erl b/lib/observer/src/observer_pro_wx.erl
index 7578215ff9..e2f3ddb02b 100644
--- a/lib/observer/src/observer_pro_wx.erl
+++ b/lib/observer/src/observer_pro_wx.erl
@@ -1,7 +1,7 @@
%%
%% %CopyrightBegin%
%%
-%% Copyright Ericsson AB 2011. All Rights Reserved.
+%% Copyright Ericsson AB 2011-2012. All Rights Reserved.
%%
%% The contents of this file are subject to the Erlang Public License,
%% Version 1.1, (the "License"); you may not use this file except in
@@ -191,13 +191,20 @@ dump_to_file(Parent, FileName, Holder) ->
start_procinfo(undefined, _Frame, Opened) ->
Opened;
start_procinfo(Pid, Frame, Opened) ->
- case lists:member(Pid, Opened) of
- true ->
- Opened;
- false ->
- observer_procinfo:start(Pid, Frame, self()),
- [Pid | Opened]
+ %% This code doesn't work until we collect which windows have been
+ %% closed maybe it should moved to observer_wx.erl
+ %% and add a global menu which remembers windows.
+ %% case lists:keyfind(Pid, 1, Opened) of
+ %% false ->
+ case observer_procinfo:start(Pid, Frame, self()) of
+ {error, _} -> Opened;
+ PI -> [{Pid, PI} | Opened]
end.
+ %%;
+ %% {_, PI} ->
+ %% wxFrame:raise(PI),
+ %% Opened
+ %% end.
call(Holder, What) ->
Ref = erlang:monitor(process, Holder),