<commit_before>function MtkWindow (settings) {
    MtkContainer.call (this, settings);

    MtkStyle.Reload ();

    this.Xaml = this.Control.Content.Root;
    this.Realize ();

    this.Override ("OnSizeAllocationRequest", function () {
        var self = this;
        return { 
            Width: self.Control.Content.ActualWidth, 
            Height: self.Control.Content.ActualHeight,
            Top: 0,
            Left: 0
        };
    });

    this.Virtual ("SetFullScreen", function (fs) this.Control.Content.FullScreen = fs);
    this.Virtual ("GetFullScreen", function () this.Control.Content.FullScreen);
    this.Virtual ("OnFullScreenChange", function () this.QueueResize ());
    this.Virtual ("OnToggleFullScreen", function () {
        this.SetFullScreen (!this.GetFullScreen ());
        this.RaiseEvent ("ToggleFullScreen", this.GetFullScreen ());
    });

    this.ToggleFullScreen = function () this.OnToggleFullScreen ();

    this.Control.Content.OnResize = delegate (this, this.QueueResize);
    this.Control.Content.OnFullScreenChange = delegate (this, this.OnFullScreenChange);
    this.MapProperties (["Background"]);

    this.AfterConstructed ();
}

<commit_msg>Moved a lot of code from here to MtkScreen<commit_after>function MtkWindow (settings) {
    MtkContainer.call (this, settings);

    MtkStyle.Reload ();

    this.Xaml = this.Screen.Xaml;
    this.Realize ();

    this.Override ("OnSizeAllocationRequest", function () {
        var self = this;
        return { 
            Width: self.Screen.Width, 
            Height: self.Screen.Height,
            Top: 0,
            Left: 0
        };
    });

    this.MapProperties (["Background"]);

    this.Screen.AddEventListener ("ScreenSizeChanged", delegate (this, function () this.QueueResize ()));
    this.Screen.AddEventListener ("FullScreenChanged", delegate (this, function () this.QueueResize ()));
    
    this.AfterConstructed ();
}


{'fraction_non_alphanumeric': 0.13164687661331956, 'fraction_numerical': 0.002065049044914817, 'mean_word_length': 2.8837675350701404, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2942171', 'n_tokens_mistral': 562, 'n_tokens_neox': 541, 'n_words': 109}