(
request: Entity<RequestEntity>,
initial_body_type: BodyType,
cx: &mut Context<Self>,
)
| 54 | initial_form_data: Option<HashMap<String, String>>, |
| 55 | initial_multipart_data: Option<Vec<MultipartField>>, |
| 56 | completion_engine: Option<CompletionEngine>, |
| 57 | } |
| 58 | |
| 59 | impl RequestView { |
| 60 | pub fn new( |
| 61 | request: Entity<RequestEntity>, |
| 62 | initial_body_type: BodyType, |
| 63 | cx: &mut Context<Self>, |
| 64 | ) -> Self { |
| 65 | cx.subscribe(&request, |_this, _request, _event: &RequestEvent, cx| { |
| 66 | cx.notify(); |
| 67 | }) |
| 68 | .detach(); |
| 69 | |
| 70 | Self { |
| 71 | request, |
| 72 | active_tab: RequestTab::Body, |
| 73 | tab_transition: TabTransition::default(), |
| 74 | body_editor: None, |
| 75 | body_type: initial_body_type, |
| 76 | last_applied_body_type: initial_body_type, |
| 77 | body_type_selector: None, |
| 78 | form_data_editor: None, |
| 79 | multipart_form_data_editor: None, |
| 80 | header_editor: None, |
| 81 | params_editor: None, |
| 82 | auth_editor: None, |
| 83 | focus_handle: cx.focus_handle(), |
| 84 | wrap_lines: true, |
| 85 | initial_body_content: None, |
| 86 | initial_form_data: None, |
| 87 | initial_multipart_data: None, |
no test coverage detected