mirror of
https://github.com/ghostty-org/ghostty.git
synced 2026-04-19 05:50:27 +00:00
Add the surface context to the Surface's setParent
In order to set the private context variable so that initiSurface can use it.
This commit is contained in:
@@ -699,6 +699,7 @@ pub const Surface = extern struct {
|
||||
pub fn setParent(
|
||||
self: *Self,
|
||||
parent: *CoreSurface,
|
||||
context: apprt.surface.NewSurfaceContext,
|
||||
) void {
|
||||
const priv = self.private();
|
||||
|
||||
@@ -709,6 +710,9 @@ pub const Surface = extern struct {
|
||||
return;
|
||||
}
|
||||
|
||||
// Store the context so initSurface can use it
|
||||
priv.context = context;
|
||||
|
||||
// Setup our font size
|
||||
const font_size_ptr = glib.ext.create(font.face.DesiredSize);
|
||||
errdefer glib.ext.destroy(font_size_ptr);
|
||||
|
||||
Reference in New Issue
Block a user