gecko-dev/browser/devtools/webconsole/PropertyPanel.jsm
Rob Campbell 05efe27693 Bug 579909 - Move WebConsole code to browser; f=nfitzgerald r=dtownsend,ddahl,gavin.sharp
--HG--
rename : toolkit/components/console/hudservice/AutocompletePopup.jsm => browser/devtools/webconsole/AutocompletePopup.jsm
rename : toolkit/components/console/hudservice/HUDService.jsm => browser/devtools/webconsole/HUDService.jsm
rename : toolkit/components/console/hudservice/Makefile.in => browser/devtools/webconsole/Makefile.in
rename : toolkit/components/console/hudservice/NetworkHelper.jsm => browser/devtools/webconsole/NetworkHelper.jsm
rename : toolkit/components/console/hudservice/NetworkPanel.xhtml => browser/devtools/webconsole/NetworkPanel.xhtml
rename : toolkit/components/console/hudservice/PropertyPanel.jsm => browser/devtools/webconsole/PropertyPanel.jsm
rename : toolkit/components/console/hudservice/tests/Makefile.in => browser/devtools/webconsole/test/Makefile.in
rename : toolkit/components/console/hudservice/tests/browser/Makefile.in => browser/devtools/webconsole/test/browser/Makefile.in
rename : toolkit/components/console/hudservice/tests/browser/browser_warn_user_about_replaced_api.js => browser/devtools/webconsole/test/browser/browser_warn_user_about_replaced_api.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_abbreviate_source_url.js => browser/devtools/webconsole/test/browser/browser_webconsole_abbreviate_source_url.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_basic_net_logging.js => browser/devtools/webconsole/test/browser/browser_webconsole_basic_net_logging.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_578437_page_reload.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_578437_page_reload.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_579412_input_focus.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_579412_input_focus.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_580001_closing_after_completion.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_580001_closing_after_completion.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_580030_errors_after_page_reload.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_580030_errors_after_page_reload.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_580400_groups.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_580400_groups.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_580454_timestamp_l10n.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_580454_timestamp_l10n.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_581231_close_button.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_581231_close_button.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_582201_duplicate_errors.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_582201_duplicate_errors.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_583816_tab_focus.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_583816_tab_focus.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_585237_line_limit.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_585237_line_limit.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_585956_console_trace.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_585956_console_trace.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_585991_autocomplete_keys.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_585991_autocomplete_keys.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_585991_autocomplete_popup.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_585991_autocomplete_popup.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_586388_select_all.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_586388_select_all.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_587617_output_copy.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_587617_output_copy.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_588342_document_focus.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_588342_document_focus.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_588730_text_node_insertion.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_588730_text_node_insertion.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_588967_input_expansion.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_588967_input_expansion.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_589162_css_filter.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_589162_css_filter.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_592442_closing_brackets.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_592442_closing_brackets.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_593003_iframe_wrong_hud.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_593003_iframe_wrong_hud.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_594477_clickable_output.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_594477_clickable_output.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_594497_history_arrow_keys.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_594497_history_arrow_keys.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_595223_file_uri.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_595223_file_uri.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_595350_multiple_windows_and_tabs.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_595350_multiple_windows_and_tabs.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_595934_message_categories.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_595934_message_categories.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_597103_deactivateHUDForContext_unfocused_window.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_597103_deactivateHUDForContext_unfocused_window.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_597136_external_script_errors.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_597136_external_script_errors.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_597136_network_requests_from_chrome.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_597136_network_requests_from_chrome.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_597460_filter_scroll.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_597460_filter_scroll.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_597756_reopen_closed_tab.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_597756_reopen_closed_tab.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_598357_jsterm_output.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_598357_jsterm_output.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_599725_response_headers.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_599725_response_headers.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_600183_charset.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_600183_charset.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_601177_log_levels.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_601177_log_levels.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_601352_scroll.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_601352_scroll.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_601667_filter_buttons.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_601667_filter_buttons.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_601909_remember_height.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_601909_remember_height.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_602572_log_bodies_checkbox.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_602572_log_bodies_checkbox.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_603750_websocket.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_603750_websocket.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_611795.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_611795.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_613013_console_api_iframe.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_613013_console_api_iframe.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_613280_jsterm_copy.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_613280_jsterm_copy.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_613642_maintain_scroll.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_613642_maintain_scroll.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_613642_prune_scroll.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_613642_prune_scroll.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_614793_jsterm_scroll.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_614793_jsterm_scroll.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_618078_network_exceptions.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_618078_network_exceptions.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_618311_close_panels.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_618311_close_panels.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_618311_private_browsing.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_618311_private_browsing.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_621644_jsterm_dollar.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_621644_jsterm_dollar.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_626484_output_copy_order.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_626484_output_copy_order.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_630733_response_redirect_headers.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_630733_response_redirect_headers.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_632275_getters_document_width.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_632275_getters_document_width.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_632347_iterators_generators.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_632347_iterators_generators.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_632817.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_632817.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_642108_pruneTest.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_642108_pruneTest.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_642615_autocomplete.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_642615_autocomplete.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_644419_log_limits.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_644419_log_limits.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_646025_console_file_location.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_646025_console_file_location.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_651501_document_body_autocomplete.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_651501_document_body_autocomplete.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_660806_history_nav.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_660806_history_nav.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_bug_663443_panel_title.js => browser/devtools/webconsole/test/browser/browser_webconsole_bug_663443_panel_title.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_chrome.js => browser/devtools/webconsole/test/browser/browser_webconsole_chrome.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_completion.js => browser/devtools/webconsole/test/browser/browser_webconsole_completion.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_console_extras.js => browser/devtools/webconsole/test/browser/browser_webconsole_console_extras.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_console_logging_api.js => browser/devtools/webconsole/test/browser/browser_webconsole_console_logging_api.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_consoleonpage.js => browser/devtools/webconsole/test/browser/browser_webconsole_consoleonpage.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_copying_multiple_messages_inserts_newlines_in_between.js => browser/devtools/webconsole/test/browser/browser_webconsole_copying_multiple_messages_inserts_newlines_in_between.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_execution_scope.js => browser/devtools/webconsole/test/browser/browser_webconsole_execution_scope.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_history.js => browser/devtools/webconsole/test/browser/browser_webconsole_history.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_hud_getters.js => browser/devtools/webconsole/test/browser/browser_webconsole_hud_getters.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_js_input_and_output_styling.js => browser/devtools/webconsole/test/browser/browser_webconsole_js_input_and_output_styling.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_js_input_expansion.js => browser/devtools/webconsole/test/browser/browser_webconsole_js_input_expansion.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_jsterm.js => browser/devtools/webconsole/test/browser/browser_webconsole_jsterm.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_live_filtering_of_message_types.js => browser/devtools/webconsole/test/browser/browser_webconsole_live_filtering_of_message_types.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_live_filtering_on_search_strings.js => browser/devtools/webconsole/test/browser/browser_webconsole_live_filtering_on_search_strings.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_log_node_classes.js => browser/devtools/webconsole/test/browser/browser_webconsole_log_node_classes.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_message_node_id.js => browser/devtools/webconsole/test/browser/browser_webconsole_message_node_id.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_netlogging.js => browser/devtools/webconsole/test/browser/browser_webconsole_netlogging.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_network_panel.js => browser/devtools/webconsole/test/browser/browser_webconsole_network_panel.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_notifications.js => browser/devtools/webconsole/test/browser/browser_webconsole_notifications.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_null_and_undefined_output.js => browser/devtools/webconsole/test/browser/browser_webconsole_null_and_undefined_output.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_output_order.js => browser/devtools/webconsole/test/browser/browser_webconsole_output_order.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_position_ui.js => browser/devtools/webconsole/test/browser/browser_webconsole_position_ui.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_property_panel.js => browser/devtools/webconsole/test/browser/browser_webconsole_property_panel.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_property_provider.js => browser/devtools/webconsole/test/browser/browser_webconsole_property_provider.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_registries.js => browser/devtools/webconsole/test/browser/browser_webconsole_registries.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_storage_create_display.js => browser/devtools/webconsole/test/browser/browser_webconsole_storage_create_display.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_storage_iteration.js => browser/devtools/webconsole/test/browser/browser_webconsole_storage_iteration.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_storage_record_entry.js => browser/devtools/webconsole/test/browser/browser_webconsole_storage_record_entry.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_storage_record_many_entries.js => browser/devtools/webconsole/test/browser/browser_webconsole_storage_record_many_entries.js
rename : toolkit/components/console/hudservice/tests/browser/browser_webconsole_view_source.js => browser/devtools/webconsole/test/browser/browser_webconsole_view_source.js
rename : toolkit/components/console/hudservice/tests/browser/head.js => browser/devtools/webconsole/test/browser/head.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-585956-console-trace.html => browser/devtools/webconsole/test/browser/test-bug-585956-console-trace.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-593003-iframe-wrong-hud-iframe.html => browser/devtools/webconsole/test/browser/test-bug-593003-iframe-wrong-hud-iframe.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-593003-iframe-wrong-hud.html => browser/devtools/webconsole/test/browser/test-bug-593003-iframe-wrong-hud.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-canvas-css.html => browser/devtools/webconsole/test/browser/test-bug-595934-canvas-css.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-canvas-css.js => browser/devtools/webconsole/test/browser/test-bug-595934-canvas-css.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-canvas.html => browser/devtools/webconsole/test/browser/test-bug-595934-canvas.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-canvas.js => browser/devtools/webconsole/test/browser/test-bug-595934-canvas.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-css-loader.css => browser/devtools/webconsole/test/browser/test-bug-595934-css-loader.css
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-css-loader.css^headers^ => browser/devtools/webconsole/test/browser/test-bug-595934-css-loader.css^headers^
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-css-loader.html => browser/devtools/webconsole/test/browser/test-bug-595934-css-loader.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-css-parser.css => browser/devtools/webconsole/test/browser/test-bug-595934-css-parser.css
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-css-parser.html => browser/devtools/webconsole/test/browser/test-bug-595934-css-parser.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-dom-events-external2.html => browser/devtools/webconsole/test/browser/test-bug-595934-dom-events-external2.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-dom-events-external2.js => browser/devtools/webconsole/test/browser/test-bug-595934-dom-events-external2.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-dom-events.html => browser/devtools/webconsole/test/browser/test-bug-595934-dom-events.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-dom-html-external.html => browser/devtools/webconsole/test/browser/test-bug-595934-dom-html-external.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-dom-html-external.js => browser/devtools/webconsole/test/browser/test-bug-595934-dom-html-external.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-dom-html.html => browser/devtools/webconsole/test/browser/test-bug-595934-dom-html.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-empty-getelementbyid.html => browser/devtools/webconsole/test/browser/test-bug-595934-empty-getelementbyid.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-empty-getelementbyid.js => browser/devtools/webconsole/test/browser/test-bug-595934-empty-getelementbyid.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-html.html => browser/devtools/webconsole/test/browser/test-bug-595934-html.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-image.html => browser/devtools/webconsole/test/browser/test-bug-595934-image.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-image.jpg => browser/devtools/webconsole/test/browser/test-bug-595934-image.jpg
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-imagemap.html => browser/devtools/webconsole/test/browser/test-bug-595934-imagemap.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-malformedxml-external.html => browser/devtools/webconsole/test/browser/test-bug-595934-malformedxml-external.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-malformedxml-external.xml => browser/devtools/webconsole/test/browser/test-bug-595934-malformedxml-external.xml
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-malformedxml.xhtml => browser/devtools/webconsole/test/browser/test-bug-595934-malformedxml.xhtml
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-svg.xhtml => browser/devtools/webconsole/test/browser/test-bug-595934-svg.xhtml
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-workers.html => browser/devtools/webconsole/test/browser/test-bug-595934-workers.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-595934-workers.js => browser/devtools/webconsole/test/browser/test-bug-595934-workers.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-597136-external-script-errors.html => browser/devtools/webconsole/test/browser/test-bug-597136-external-script-errors.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-597136-external-script-errors.js => browser/devtools/webconsole/test/browser/test-bug-597136-external-script-errors.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-597756-reopen-closed-tab.html => browser/devtools/webconsole/test/browser/test-bug-597756-reopen-closed-tab.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-599725-response-headers.sjs => browser/devtools/webconsole/test/browser/test-bug-599725-response-headers.sjs
rename : toolkit/components/console/hudservice/tests/browser/test-bug-600183-charset.html => browser/devtools/webconsole/test/browser/test-bug-600183-charset.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-600183-charset.html^headers^ => browser/devtools/webconsole/test/browser/test-bug-600183-charset.html^headers^
rename : toolkit/components/console/hudservice/tests/browser/test-bug-601177-log-levels.html => browser/devtools/webconsole/test/browser/test-bug-601177-log-levels.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-601177-log-levels.js => browser/devtools/webconsole/test/browser/test-bug-601177-log-levels.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-603750-websocket.html => browser/devtools/webconsole/test/browser/test-bug-603750-websocket.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-603750-websocket.js => browser/devtools/webconsole/test/browser/test-bug-603750-websocket.js
rename : toolkit/components/console/hudservice/tests/browser/test-bug-613013-console-api-iframe.html => browser/devtools/webconsole/test/browser/test-bug-613013-console-api-iframe.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-618078-network-exceptions.html => browser/devtools/webconsole/test/browser/test-bug-618078-network-exceptions.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-621644-jsterm-dollar.html => browser/devtools/webconsole/test/browser/test-bug-621644-jsterm-dollar.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-630733-response-redirect-headers.sjs => browser/devtools/webconsole/test/browser/test-bug-630733-response-redirect-headers.sjs
rename : toolkit/components/console/hudservice/tests/browser/test-bug-632275-getters.html => browser/devtools/webconsole/test/browser/test-bug-632275-getters.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-632347-iterators-generators.html => browser/devtools/webconsole/test/browser/test-bug-632347-iterators-generators.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-644419-log-limits.html => browser/devtools/webconsole/test/browser/test-bug-644419-log-limits.html
rename : toolkit/components/console/hudservice/tests/browser/test-bug-646025-console-file-location.html => browser/devtools/webconsole/test/browser/test-bug-646025-console-file-location.html
rename : toolkit/components/console/hudservice/tests/browser/test-console-extras.html => browser/devtools/webconsole/test/browser/test-console-extras.html
rename : toolkit/components/console/hudservice/tests/browser/test-console-replaced-api.html => browser/devtools/webconsole/test/browser/test-console-replaced-api.html
rename : toolkit/components/console/hudservice/tests/browser/test-console.html => browser/devtools/webconsole/test/browser/test-console.html
rename : toolkit/components/console/hudservice/tests/browser/test-data.json => browser/devtools/webconsole/test/browser/test-data.json
rename : toolkit/components/console/hudservice/tests/browser/test-duplicate-error.html => browser/devtools/webconsole/test/browser/test-duplicate-error.html
rename : toolkit/components/console/hudservice/tests/browser/test-encoding-ISO-8859-1.html => browser/devtools/webconsole/test/browser/test-encoding-ISO-8859-1.html
rename : toolkit/components/console/hudservice/tests/browser/test-error.html => browser/devtools/webconsole/test/browser/test-error.html
rename : toolkit/components/console/hudservice/tests/browser/test-file-location.js => browser/devtools/webconsole/test/browser/test-file-location.js
rename : toolkit/components/console/hudservice/tests/browser/test-filter.html => browser/devtools/webconsole/test/browser/test-filter.html
rename : toolkit/components/console/hudservice/tests/browser/test-image.png => browser/devtools/webconsole/test/browser/test-image.png
rename : toolkit/components/console/hudservice/tests/browser/test-mutation.html => browser/devtools/webconsole/test/browser/test-mutation.html
rename : toolkit/components/console/hudservice/tests/browser/test-network-request.html => browser/devtools/webconsole/test/browser/test-network-request.html
rename : toolkit/components/console/hudservice/tests/browser/test-network.html => browser/devtools/webconsole/test/browser/test-network.html
rename : toolkit/components/console/hudservice/tests/browser/test-observe-http-ajax.html => browser/devtools/webconsole/test/browser/test-observe-http-ajax.html
rename : toolkit/components/console/hudservice/tests/browser/test-own-console.html => browser/devtools/webconsole/test/browser/test-own-console.html
rename : toolkit/components/console/hudservice/tests/browser/test-property-provider.html => browser/devtools/webconsole/test/browser/test-property-provider.html
rename : toolkit/components/console/hudservice/tests/browser/testscript.js => browser/devtools/webconsole/test/browser/testscript.js
2011-07-26 12:22:51 -03:00

613 lines
17 KiB
JavaScript

/* -*- Mode: js2; js2-basic-offset: 2; indent-tabs-mode: nil; -*- */
/* vim: set ft=javascript ts=2 et sw=2 tw=80: */
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is DevTools (HeadsUpDisplay) Console Code
*
* The Initial Developer of the Original Code is
* the Mozilla Foundation.
* Portions created by the Initial Developer are Copyright (C) 2010
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Rob Campbell <rcampbell@mozilla.com>
* Julian Viereck <jviereck@mozilla.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
const Cc = Components.classes;
const Ci = Components.interfaces;
const Cu = Components.utils;
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
Cu.import("resource://gre/modules/Services.jsm");
var EXPORTED_SYMBOLS = ["PropertyPanel", "PropertyTreeView",
"namesAndValuesOf", "isNonNativeGetter"];
///////////////////////////////////////////////////////////////////////////
//// Helper for PropertyTreeView
const TYPE_OBJECT = 0, TYPE_FUNCTION = 1, TYPE_ARRAY = 2, TYPE_OTHER = 3;
/**
* Figures out the type of aObject and the string to display in the tree.
*
* @param object aObject
* The object to operate on.
* @returns object
* A object with the form:
* {
* type: TYPE_OBJECT || TYPE_FUNCTION || TYPE_ARRAY || TYPE_OTHER,
* display: string for displaying the object in the tree
* }
*/
function presentableValueFor(aObject)
{
if (aObject === null || aObject === undefined) {
return {
type: TYPE_OTHER,
display: aObject === undefined ? "undefined" : "null"
};
}
let presentable;
switch (aObject.constructor && aObject.constructor.name) {
case "Array":
return {
type: TYPE_ARRAY,
display: "Array"
};
case "String":
return {
type: TYPE_OTHER,
display: "\"" + aObject + "\""
};
case "Date":
case "RegExp":
case "Number":
case "Boolean":
return {
type: TYPE_OTHER,
display: aObject
};
case "Iterator":
return {
type: TYPE_OTHER,
display: "Iterator"
};
case "Function":
presentable = aObject.toString();
return {
type: TYPE_FUNCTION,
display: presentable.substring(0, presentable.indexOf(')') + 1)
};
default:
presentable = aObject.toString();
let m = /^\[object (\S+)\]/.exec(presentable);
try {
if (typeof aObject == "object" && typeof aObject.next == "function" &&
m && m[1] == "Generator") {
return {
type: TYPE_OTHER,
display: m[1]
};
}
}
catch (ex) {
// window.history.next throws in the typeof check above.
return {
type: TYPE_OBJECT,
display: m ? m[1] : "Object"
};
}
if (typeof aObject == "object" && typeof aObject.__iterator__ == "function") {
return {
type: TYPE_OTHER,
display: "Iterator"
};
}
return {
type: TYPE_OBJECT,
display: m ? m[1] : "Object"
};
}
}
/**
* Tells if the given function is native or not.
*
* @param function aFunction
* The function you want to check if it is native or not.
*
* @return boolean
* True if the given function is native, false otherwise.
*/
function isNativeFunction(aFunction)
{
return typeof aFunction == "function" && !("prototype" in aFunction);
}
/**
* Tells if the given property of the provided object is a non-native getter or
* not.
*
* @param object aObject
* The object that contains the property.
*
* @param string aProp
* The property you want to check if it is a getter or not.
*
* @return boolean
* True if the given property is a getter, false otherwise.
*/
function isNonNativeGetter(aObject, aProp) {
if (typeof aObject != "object") {
return false;
}
let desc;
while (aObject) {
try {
if (desc = Object.getOwnPropertyDescriptor(aObject, aProp)) {
break;
}
}
catch (ex) {
// Native getters throw here. See bug 520882.
if (ex.name == "NS_ERROR_XPC_BAD_CONVERT_JS" ||
ex.name == "NS_ERROR_XPC_BAD_OP_ON_WN_PROTO") {
return false;
}
throw ex;
}
aObject = Object.getPrototypeOf(aObject);
}
if (desc && desc.get && !isNativeFunction(desc.get)) {
return true;
}
return false;
}
/**
* Get an array of property name value pairs for the tree.
*
* @param object aObject
* The object to get properties for.
* @returns array of object
* Objects have the name, value, display, type, children properties.
*/
function namesAndValuesOf(aObject)
{
let pairs = [];
let value, presentable;
let isDOMDocument = aObject instanceof Ci.nsIDOMDocument;
for (var propName in aObject) {
// See bug 632275: skip deprecated width and height properties.
if (isDOMDocument && (propName == "width" || propName == "height")) {
continue;
}
// Also skip non-native getters.
if (isNonNativeGetter(aObject, propName)) {
value = ""; // Value is never displayed.
presentable = {type: TYPE_OTHER, display: "Getter"};
}
else {
try {
value = aObject[propName];
presentable = presentableValueFor(value);
}
catch (ex) {
continue;
}
}
let pair = {};
pair.name = propName;
pair.display = propName + ": " + presentable.display;
pair.type = presentable.type;
pair.value = value;
// Convert the pair.name to a number for later sorting.
pair.nameNumber = parseFloat(pair.name)
if (isNaN(pair.nameNumber)) {
pair.nameNumber = false;
}
pairs.push(pair);
}
pairs.sort(function(a, b)
{
// Sort numbers.
if (a.nameNumber !== false && b.nameNumber === false) {
return -1;
}
else if (a.nameNumber === false && b.nameNumber !== false) {
return 1;
}
else if (a.nameNumber !== false && b.nameNumber !== false) {
return a.nameNumber - b.nameNumber;
}
// Sort string.
else if (a.name < b.name) {
return -1;
}
else if (a.name > b.name) {
return 1;
}
else {
return 0;
}
});
return pairs;
}
///////////////////////////////////////////////////////////////////////////
//// PropertyTreeView.
/**
* This is an implementation of the nsITreeView interface. For comments on the
* interface properties, see the documentation:
* https://developer.mozilla.org/en/XPCOM_Interface_Reference/nsITreeView
*/
var PropertyTreeView = function() {
this._rows = [];
};
PropertyTreeView.prototype = {
/**
* Stores the visible rows of the tree.
*/
_rows: null,
/**
* Stores the nsITreeBoxObject for this tree.
*/
_treeBox: null,
/**
* Use this setter to update the content of the tree.
*
* @param object aObject
* The new object to be displayed in the tree.
* @returns void
*/
set data(aObject) {
let oldLen = this._rows.length;
this._rows = this.getChildItems(aObject, true);
if (this._treeBox) {
this._treeBox.beginUpdateBatch();
if (oldLen) {
this._treeBox.rowCountChanged(0, -oldLen);
}
this._treeBox.rowCountChanged(0, this._rows.length);
this._treeBox.endUpdateBatch();
}
},
/**
* Generates the child items for the treeView of a given aItem. If there is
* already a children property on the aItem, this cached one is returned.
*
* @param object aItem
* An item of the tree's elements to generate the children for.
* @param boolean aRootElement
* If set, aItem is handled as an JS object and not as an item
* element of the tree.
* @returns array of objects
* Child items of aItem.
*/
getChildItems: function(aItem, aRootElement)
{
// If item.children is an array, then the children has already been
// computed and can get returned directly.
// Skip this checking if aRootElement is true. It could happen, that aItem
// is passed as ({children:[1,2,3]}) which would be true, although these
// "kind" of children has no value/type etc. data as needed to display in
// the tree. As the passed ({children:[1,2,3]}) are instanceof
// itsWindow.Array and not this modules's global Array
// aItem.children instanceof Array can't be true, but for saftey the
// !aRootElement is kept here.
if (!aRootElement && aItem && aItem.children instanceof Array) {
return aItem.children;
}
let pairs;
let newPairLevel;
if (!aRootElement) {
newPairLevel = aItem.level + 1;
aItem = aItem.value;
}
else {
newPairLevel = 0;
}
pairs = namesAndValuesOf(aItem);
for each (var pair in pairs) {
pair.level = newPairLevel;
pair.isOpened = false;
pair.children = pair.type == TYPE_OBJECT || pair.type == TYPE_FUNCTION ||
pair.type == TYPE_ARRAY;
}
return pairs;
},
/** nsITreeView interface implementation **/
selection: null,
get rowCount() { return this._rows.length; },
setTree: function(treeBox) { this._treeBox = treeBox; },
getCellText: function(idx, column) { return this._rows[idx].display; },
getLevel: function(idx) { return this._rows[idx].level; },
isContainer: function(idx) { return !!this._rows[idx].children; },
isContainerOpen: function(idx) { return this._rows[idx].isOpened; },
isContainerEmpty: function(idx) { return false; },
isSeparator: function(idx) { return false; },
isSorted: function() { return false; },
isEditable: function(idx, column) { return false; },
isSelectable: function(row, col) { return true; },
getParentIndex: function(idx)
{
if (this.getLevel(idx) == 0) {
return -1;
}
for (var t = idx - 1; t >= 0 ; t--) {
if (this.isContainer(t)) {
return t;
}
}
return -1;
},
hasNextSibling: function(idx, after)
{
var thisLevel = this.getLevel(idx);
return this._rows.slice(after + 1).some(function (r) r.level == thisLevel);
},
toggleOpenState: function(idx)
{
var item = this._rows[idx];
if (!item.children) {
return;
}
this._treeBox.beginUpdateBatch();
if (item.isOpened) {
item.isOpened = false;
var thisLevel = item.level;
var t = idx + 1, deleteCount = 0;
while (t < this._rows.length && this.getLevel(t++) > thisLevel) {
deleteCount++;
}
if (deleteCount) {
this._rows.splice(idx + 1, deleteCount);
this._treeBox.rowCountChanged(idx + 1, -deleteCount);
}
}
else {
item.isOpened = true;
var toInsert = this.getChildItems(item);
item.children = toInsert;
this._rows.splice.apply(this._rows, [idx + 1, 0].concat(toInsert));
this._treeBox.rowCountChanged(idx + 1, toInsert.length);
}
this._treeBox.invalidateRow(idx);
this._treeBox.endUpdateBatch();
},
getImageSrc: function(idx, column) { },
getProgressMode : function(idx,column) { },
getCellValue: function(idx, column) { },
cycleHeader: function(col, elem) { },
selectionChanged: function() { },
cycleCell: function(idx, column) { },
performAction: function(action) { },
performActionOnCell: function(action, index, column) { },
performActionOnRow: function(action, row) { },
getRowProperties: function(idx, column, prop) { },
getCellProperties: function(idx, column, prop) { },
getColumnProperties: function(column, element, prop) { },
setCellValue: function(row, col, value) { },
setCellText: function(row, col, value) { },
drop: function(index, orientation, dataTransfer) { },
canDrop: function(index, orientation, dataTransfer) { return false; }
};
///////////////////////////////////////////////////////////////////////////
//// Helper for creating the panel.
/**
* Creates a DOMNode and sets all the attributes of aAttributes on the created
* element.
*
* @param nsIDOMDocument aDocument
* Document to create the new DOMNode.
* @param string aTag
* Name of the tag for the DOMNode.
* @param object aAttributes
* Attributes set on the created DOMNode.
* @returns nsIDOMNode
*/
function createElement(aDocument, aTag, aAttributes)
{
let node = aDocument.createElement(aTag);
for (var attr in aAttributes) {
node.setAttribute(attr, aAttributes[attr]);
}
return node;
}
/**
* Creates a new DOMNode and appends it to aParent.
*
* @param nsIDOMDocument aDocument
* Document to create the new DOMNode.
* @param nsIDOMNode aParent
* A parent node to append the created element.
* @param string aTag
* Name of the tag for the DOMNode.
* @param object aAttributes
* Attributes set on the created DOMNode.
* @returns nsIDOMNode
*/
function appendChild(aDocument, aParent, aTag, aAttributes)
{
let node = createElement(aDocument, aTag, aAttributes);
aParent.appendChild(node);
return node;
}
///////////////////////////////////////////////////////////////////////////
//// PropertyPanel
/**
* Creates a new PropertyPanel.
*
* @param nsIDOMNode aParent
* Parent node to append the created panel to.
* @param nsIDOMDocument aDocument
* Document to create the new nodes on.
* @param string aTitle
* Title for the panel.
* @param string aObject
* Object to display in the tree.
* @param array of objects aButtons
* Array with buttons to display at the bottom of the panel.
*/
function PropertyPanel(aParent, aDocument, aTitle, aObject, aButtons)
{
// Create the underlying panel
this.panel = createElement(aDocument, "panel", {
label: aTitle,
titlebar: "normal",
noautofocus: "true",
noautohide: "true",
close: "true",
});
// Create the tree.
let tree = this.tree = createElement(aDocument, "tree", {
flex: 1,
hidecolumnpicker: "true"
});
let treecols = aDocument.createElement("treecols");
appendChild(aDocument, treecols, "treecol", {
primary: "true",
flex: 1,
hideheader: "true",
ignoreincolumnpicker: "true"
});
tree.appendChild(treecols);
tree.appendChild(aDocument.createElement("treechildren"));
this.panel.appendChild(tree);
// Create the footer.
let footer = createElement(aDocument, "hbox", { align: "end" });
appendChild(aDocument, footer, "spacer", { flex: 1 });
// The footer can have butttons.
let self = this;
if (aButtons) {
aButtons.forEach(function(button) {
let buttonNode = appendChild(aDocument, footer, "button", {
label: button.label,
accesskey: button.accesskey || "",
class: button.class || "",
});
buttonNode.addEventListener("command", button.oncommand, false);
});
}
appendChild(aDocument, footer, "resizer", { dir: "bottomend" });
this.panel.appendChild(footer);
aParent.appendChild(this.panel);
// Create the treeView object.
this.treeView = new PropertyTreeView();
this.treeView.data = aObject;
// Set the treeView object on the tree view. This has to be done *after* the
// panel is shown. This is because the tree binding must be attached first.
this.panel.addEventListener("popupshown", function onPopupShow()
{
self.panel.removeEventListener("popupshown", onPopupShow, false);
self.tree.view = self.treeView;
}, false);
this.panel.addEventListener("popuphidden", function onPopupHide()
{
self.panel.removeEventListener("popuphidden", onPopupHide, false);
self.destroy();
}, false);
}
/**
* Destroy the PropertyPanel. This closes the poped up panel and removes
* it from the browser DOM.
*
* @returns void
*/
PropertyPanel.prototype.destroy = function PP_destroy()
{
this.panel.parentNode.removeChild(this.panel);
this.treeView = null;
this.panel = null;
this.tree = null;
if (this.linkNode) {
this.linkNode._panelOpen = false;
this.linkNode = null;
}
}