From 549205db3dee21e83a64a01f03b1e8ed2225b276 Mon Sep 17 00:00:00 2001 From: Dan Gudmundsson Date: Fri, 11 Oct 2013 16:56:24 +0200 Subject: observer: Consolidate the view of process information Add clickable links to processes in process info Use html pages (contains clickable processes) to view messages, dictionary and other information. --- lib/observer/src/observer_wx.erl | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'lib/observer/src/observer_wx.erl') diff --git a/lib/observer/src/observer_wx.erl b/lib/observer/src/observer_wx.erl index 3afe933e5a..9839f8bf7b 100644 --- a/lib/observer/src/observer_wx.erl +++ b/lib/observer/src/observer_wx.erl @@ -346,6 +346,22 @@ handle_info({nodedown, Node}, create_txt_dialog(Frame, Msg, "Node down", ?wxICON_EXCLAMATION), {noreply, State3}; +handle_info({open_link, Pid0}, State = #state{pro_panel=ProcViewer, frame=Frame}) -> + Pid = case Pid0 of + [_|_] -> try list_to_pid(Pid0) catch _:_ -> Pid0 end; + _ -> Pid0 + end, + %% Forward to process tab + case is_pid(Pid) of + true -> wx_object:get_pid(ProcViewer) ! {procinfo_open, Pid}; + false -> + Msg = io_lib:format("Information about ~p is not available or implemented",[Pid]), + Info = wxMessageDialog:new(Frame, Msg), + wxMessageDialog:showModal(Info), + wxMessageDialog:destroy(Info) + end, + {noreply, State}; + handle_info({'EXIT', Pid, _Reason}, State) -> io:format("Child (~s) crashed exiting: ~p ~p~n", [pid2panel(Pid, State), Pid,_Reason]), -- cgit v1.2.3