Skip to content

Commit

Permalink
gschema: remove window position
Browse files Browse the repository at this point in the history
  • Loading branch information
danirabbit committed Nov 10, 2023
1 parent d9978f4 commit dc2f744
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 14 deletions.
5 changes: 0 additions & 5 deletions data/io.elementary.code.gschema.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,6 @@
<summary>The saved state of the window.</summary>
<description>The saved state of the window.</description>
</key>
<key name="window-position" type="(ii)">
<default>(-1, -1)</default>
<summary>Window position</summary>
<description>Most recent window position (x, y)</description>
</key>
<key name="window-size" type="(ii)">
<default>(850, 550)</default>
<summary>Most recent window size</summary>
Expand Down
9 changes: 0 additions & 9 deletions src/MainWindow.vala
Original file line number Diff line number Diff line change
Expand Up @@ -265,10 +265,6 @@ namespace Scratch {
fullscreen ();
break;
default:
Scratch.saved_state.get ("window-position", "(ii)", out rect.x, out rect.y);
if (rect.x != -1 && rect.y != -1) {
move (rect.x, rect.y);
}
break;
}

Expand Down Expand Up @@ -718,11 +714,6 @@ namespace Scratch {
Scratch.saved_state.set ("window-size", "(ii)", width, height);
}

// Save window position
int x, y;
get_position (out x, out y);
Scratch.saved_state.set ("window-position", "(ii)", x, y);

// Plugin panes size
Scratch.saved_state.set_int ("hp1-size", hp1.get_position ());
Scratch.saved_state.set_int ("vp-size", vp.get_position ());
Expand Down

0 comments on commit dc2f744

Please sign in to comment.