Remove wx logging junk
This commit is contained in:
+8
-5
@@ -276,7 +276,8 @@ handle_cast(Unexpected, State) ->
|
||||
|
||||
|
||||
handle_info(retire, State) ->
|
||||
retire(State);
|
||||
ok = retire(State),
|
||||
{noreply, State};
|
||||
handle_info(Unexpected, State) ->
|
||||
ok = log(warning, "Unexpected info: ~tp~n", [Unexpected]),
|
||||
{noreply, State}.
|
||||
@@ -295,7 +296,8 @@ handle_event(#wx{event = #wxCommand{type = command_button_clicked}, id = ID},
|
||||
ok = copy(State),
|
||||
{noreply, State};
|
||||
handle_event(#wx{event = #wxClose{}}, State) ->
|
||||
retire(State);
|
||||
ok = retire(State),
|
||||
{noreply, State};
|
||||
handle_event(Event, State) ->
|
||||
ok = tell(info, "Unexpected event ~tp State: ~tp~n", [Event, State]),
|
||||
{noreply, State}.
|
||||
@@ -305,11 +307,12 @@ code_change(_, State, _) ->
|
||||
{ok, State}.
|
||||
|
||||
|
||||
retire(State = #s{frame = Frame}) ->
|
||||
ok = wxWindow:destroy(Frame),
|
||||
{stop, normal, State}.
|
||||
retire(#s{frame = Frame}) ->
|
||||
wxWindow:destroy(Frame).
|
||||
|
||||
|
||||
terminate(wx_deleted, _) ->
|
||||
wx:destroy();
|
||||
terminate(Reason, State) ->
|
||||
ok = log(info, "Reason: ~tp, State: ~tp", [Reason, State]),
|
||||
wx:destroy().
|
||||
|
||||
@@ -298,6 +298,8 @@ code_change(_, State, _) ->
|
||||
{ok, State}.
|
||||
|
||||
|
||||
terminate(wx_deleted, _) ->
|
||||
wx:destroy();
|
||||
terminate(Reason, State) ->
|
||||
ok = log(info, "Reason: ~tp, State: ~tp", [Reason, State]),
|
||||
wx:destroy().
|
||||
|
||||
Reference in New Issue
Block a user