Skip to content

Conversation

@mrobinson
Copy link
Member

These two new API method make it easier to enable and disable the back
and forward buttons in the browser UI. In addition, they are used to
enable and disable the context menu items for "Back" and "Forward". This
is something that is much, much easier to do in the embedding layer,
rather than in script.

In addition, the new methods are wired up to the buttons in Servoshell.

Testing: This change includes a new API test.

@mrobinson mrobinson requested a review from atbrakhi as a code owner November 12, 2025 16:27
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Nov 12, 2025
/// Whether the location has been edited by the user without clicking Go.
location_dirty: bool,

/// The [`LoadStatus`] of the active `WebView.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/// The [`LoadStatus`] of the active `WebView.
/// The [`LoadStatus`] of the active `WebView`.

cursor: Cursor,

/// The back / forward list of this WebView.
back_foward_list: Vec<Url>,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
back_foward_list: Vec<Url>,
back_forward_list: Vec<Url>,

@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Nov 12, 2025
These two new API method make it easier to enable and disable the back
and forward buttons in the browser UI. In addition, they are used to
enable and disable the context menu items for "Back" and "Forward". This
is something that is much, much easier to do in the embedding layer,
rather than in script.

In addition, the new methods are wired up to the buttons in Servoshell.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
@mrobinson mrobinson force-pushed the can-go-forward-can-go-back branch from bb82707 to 571a384 Compare November 12, 2025 18:08
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Nov 12, 2025
@mrobinson
Copy link
Member Author

@mukilan Thank you for the review.

@mrobinson mrobinson enabled auto-merge November 12, 2025 18:08
@mrobinson mrobinson added this pull request to the merge queue Nov 12, 2025
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Nov 12, 2025
Merged via the queue into servo:main with commit 51ebbfe Nov 12, 2025
35 checks passed
@mrobinson mrobinson deleted the can-go-forward-can-go-back branch November 12, 2025 19:58
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Nov 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-awaiting-review There is new code that needs to be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants