mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-16 16:56:09 +03:00
apprt/gtk: rename parentSurface
This commit is contained in:
@ -164,8 +164,8 @@ pub const Container = union(enum) {
|
|||||||
/// surface has been initialized.
|
/// surface has been initialized.
|
||||||
realized: bool = false,
|
realized: bool = false,
|
||||||
|
|
||||||
/// See Options.parentSurface
|
/// True if this surface had a parent to start with.
|
||||||
parentSurface: bool = false,
|
parent_surface: bool = false,
|
||||||
|
|
||||||
/// The GUI container that this surface has been attached to. This
|
/// The GUI container that this surface has been attached to. This
|
||||||
/// dictates some behaviors such as new splits, etc.
|
/// dictates some behaviors such as new splits, etc.
|
||||||
@ -301,7 +301,7 @@ pub fn init(self: *Surface, app: *App, opts: Options) !void {
|
|||||||
.title_text = null,
|
.title_text = null,
|
||||||
.core_surface = undefined,
|
.core_surface = undefined,
|
||||||
.font_size = font_size,
|
.font_size = font_size,
|
||||||
.parentSurface = opts.parent != null,
|
.parent_surface = opts.parent != null,
|
||||||
.size = .{ .width = 800, .height = 600 },
|
.size = .{ .width = 800, .height = 600 },
|
||||||
.cursor_pos = .{ .x = 0, .y = 0 },
|
.cursor_pos = .{ .x = 0, .y = 0 },
|
||||||
.im_context = im_context,
|
.im_context = im_context,
|
||||||
@ -350,8 +350,8 @@ fn realize(self: *Surface) !void {
|
|||||||
// Get our new surface config
|
// Get our new surface config
|
||||||
var config = try apprt.surface.newConfig(self.app.core_app, &self.app.config);
|
var config = try apprt.surface.newConfig(self.app.core_app, &self.app.config);
|
||||||
defer config.deinit();
|
defer config.deinit();
|
||||||
if (!self.parentSurface) {
|
if (!self.parent_surface) {
|
||||||
// A hack, see the "parentSurface" field for more information.
|
// A hack, see the "parent_surface" field for more information.
|
||||||
config.@"working-directory" = self.app.config.@"working-directory";
|
config.@"working-directory" = self.app.config.@"working-directory";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user