nitpicker: rename 'displays' report to 'panorama'

... and enable report in Sculpt's report_fs.

Issue #5352
This commit is contained in:
Christian Helmuth 2024-10-21 08:51:11 +02:00
parent 2d7cd1c736
commit 679d68d470
5 changed files with 20 additions and 18 deletions

View File

@ -470,6 +470,8 @@ install_config {
<child name="config_fs_rom" label="nitpicker"/> </service>
<service name="ROM" label="focus">
<child name="nit_focus"/> </service>
<service name="Report" label="panorama">
<child name="fs_report"/> </service>
<service name="Report" label="keystate">
<child name="report_logger"/> </service>
<service name="Report"> <child name="report_rom"/> </service>

View File

@ -1,6 +1,6 @@
<config focus="rom">
<capture/> <event/>
<report hover="yes" focus="yes" clicked="yes" keystate="no"/>
<report hover="yes" focus="yes" clicked="yes" keystate="no" panorama="yes"/>
<background color="#000000"/>
<domain name="overlay" layer="0" label="no" hover="always" focus="transient" content="client"/>

View File

@ -21,7 +21,7 @@
<service name="Gui"/> <service name="Capture"/>
</provides>
<config request_framebuffer="no">
<report displays="yes"/>
<report panorama="yes"/>
<capture/>
<domain name="" layer="1" content="client" label="no" />
<default-policy domain=""/>
@ -37,7 +37,7 @@
<resource name="RAM" quantum="2M"/>
<provides> <service name="Report"/> <service name="ROM"/> </provides>
<config verbose="no">
<policy label="webcam_config -> displays" report="nitpicker_camera -> displays"/>
<policy label="webcam_config -> panorama" report="nitpicker_camera -> panorama"/>
</config>
<route>
<any-service> <parent /> </any-service>
@ -49,7 +49,7 @@
<resource name="RAM" quantum="1M"/>
<provides> <service name="ROM"/> </provides>
<config verbose="no">
<input name="capture_width" rom="displays" node="displays" default="">
<input name="capture_width" rom="panorama" node="panorama" default="">
<node type="capture">
<attribute name="width"/>
</node>
@ -93,7 +93,7 @@
</output>
</config>
<route>
<service name="ROM" label="displays"> <child name="report_rom"/> </service>
<service name="ROM" label="panorama"> <child name="report_rom"/> </service>
<any-service> <parent/> </any-service>
</route>
</start>

View File

@ -242,7 +242,7 @@ The 'keystate' attribute enables the reporting of the currently pressed keys.
The 'clicked' attribute enables the reporting of the last clicked-on unfocused
client. This report is useful for a focus-managing component to implement a
focus-on-click policy.
The 'displays' attribute enables the reporting of the panorama of displays
The 'panorama' attribute enables the reporting of the panorama of displays
described below.

View File

@ -354,7 +354,7 @@ class Nitpicker::Capture_root : public Root_component<Capture_session>
session.process_damage(); });
}
void report_displays(Xml_generator &xml, Rect const domain_panorama) const
void report_panorama(Xml_generator &xml, Rect const domain_panorama) const
{
gen_attr(xml, domain_panorama);
_sessions.for_each([&] (Capture_session const &capture) {
@ -574,7 +574,7 @@ struct Nitpicker::Main : Focus_updater, Hover_updater,
capture_buffer_size_changed();
}
void _report_displays();
void _report_panorama();
/*
* User-input policy
@ -619,7 +619,7 @@ struct Nitpicker::Main : Focus_updater, Hover_updater,
Reporter _focus_reporter = { _env, "focus" };
Reporter _keystate_reporter = { _env, "keystate" };
Reporter _clicked_reporter = { _env, "clicked" };
Reporter _displays_reporter = { _env, "displays" };
Reporter _panorama_reporter = { _env, "panorama" };
Attached_rom_dataspace _config_rom { _env, "config" };
@ -635,7 +635,7 @@ struct Nitpicker::Main : Focus_updater, Hover_updater,
*/
void gen_capture_info(Xml_generator &xml, Rect const domain_panorama) const override
{
_capture_root.report_displays(xml, domain_panorama);
_capture_root.report_panorama(xml, domain_panorama);
}
Capture_root _capture_root { _env, *this, _sliced_heap, _view_stack, *this };
@ -715,7 +715,7 @@ struct Nitpicker::Main : Focus_updater, Hover_updater,
s->notify_mode_change();
}
_report_displays();
_report_panorama();
_update_input_connection();
}
@ -870,7 +870,7 @@ struct Nitpicker::Main : Focus_updater, Hover_updater,
_update_motion_and_focus_activity_reports();
_report_displays();
_report_panorama();
}
};
@ -1019,7 +1019,7 @@ void Nitpicker::Main::_handle_config()
configure_reporter(config, _focus_reporter);
configure_reporter(config, _keystate_reporter);
configure_reporter(config, _clicked_reporter);
configure_reporter(config, _displays_reporter);
configure_reporter(config, _panorama_reporter);
capture_client_appeared_or_disappeared();
@ -1085,16 +1085,16 @@ void Nitpicker::Main::_handle_config()
}
void Nitpicker::Main::_report_displays()
void Nitpicker::Main::_report_panorama()
{
if (!_displays_reporter.enabled())
if (!_panorama_reporter.enabled())
return;
Reporter::Xml_generator xml(_displays_reporter, [&] () {
Reporter::Xml_generator xml(_panorama_reporter, [&] () {
if (_fb_screen.constructed())
xml.node("display", [&] { gen_attr(xml, _fb_screen->_rect); });
xml.node("panorama", [&] { gen_attr(xml, _fb_screen->_rect); });
_capture_root.report_displays(xml, _view_stack.bounding_box());
_capture_root.report_panorama(xml, _view_stack.bounding_box());
});
}