mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-27 02:24:18 +00:00
Add "d" for delete shortcut to flow view.
This commit is contained in:
parent
00d3395359
commit
d9fda2b207
@ -7,7 +7,7 @@ def _mkhelp():
|
|||||||
("A", "accept all intercepted connections"),
|
("A", "accept all intercepted connections"),
|
||||||
("a", "accept this intercepted connection"),
|
("a", "accept this intercepted connection"),
|
||||||
("C", "clear connection list or eventlog"),
|
("C", "clear connection list or eventlog"),
|
||||||
("d", "delete connection from view"),
|
("d", "delete flow"),
|
||||||
("l", "set limit filter pattern"),
|
("l", "set limit filter pattern"),
|
||||||
("L", "load saved flows"),
|
("L", "load saved flows"),
|
||||||
("r", "replay request"),
|
("r", "replay request"),
|
||||||
|
@ -9,6 +9,7 @@ def _mkhelp():
|
|||||||
("A", "accept all intercepted connections"),
|
("A", "accept all intercepted connections"),
|
||||||
("a", "accept this intercepted connection"),
|
("a", "accept this intercepted connection"),
|
||||||
("b", "save request/response body"),
|
("b", "save request/response body"),
|
||||||
|
("d", "delete flow"),
|
||||||
("e", "edit request/response"),
|
("e", "edit request/response"),
|
||||||
("m", "change body display mode"),
|
("m", "change body display mode"),
|
||||||
(None,
|
(None,
|
||||||
@ -444,6 +445,16 @@ class ConnectionView(common.WWrap):
|
|||||||
elif key == "A":
|
elif key == "A":
|
||||||
self.master.accept_all()
|
self.master.accept_all()
|
||||||
self.master.view_flow(self.flow)
|
self.master.view_flow(self.flow)
|
||||||
|
elif key == "d":
|
||||||
|
if self.state.flow_count() == 1:
|
||||||
|
self.master.view_connlist()
|
||||||
|
elif self.state.view.index(self.flow) == len(self.state.view)-1:
|
||||||
|
self.view_prev_flow(self.flow)
|
||||||
|
else:
|
||||||
|
self.view_next_flow(self.flow)
|
||||||
|
f = self.flow
|
||||||
|
f.kill(self.master)
|
||||||
|
self.state.delete_flow(f)
|
||||||
elif key == "e":
|
elif key == "e":
|
||||||
if self.state.view_flow_mode == common.VIEW_FLOW_REQUEST:
|
if self.state.view_flow_mode == common.VIEW_FLOW_REQUEST:
|
||||||
self.master.prompt_onekey(
|
self.master.prompt_onekey(
|
||||||
|
Loading…
Reference in New Issue
Block a user