Created
August 23, 2012 22:36
-
-
Save stober/3442853 to your computer and use it in GitHub Desktop.
Unsplit a pane.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sublime, sublime_plugin | |
class UnSplitPaneCommand(sublime_plugin.WindowCommand): | |
def run(self): | |
if self.window.num_groups() == 2: | |
for view in self.window.views_in_group(1): | |
#TODO check modified? | |
self.window.focus_view(view) | |
self.window.run_command('close_file') | |
self.window.run_command('set_layout', | |
{ | |
"cols": [0.0, 1.0, 1.0], | |
"rows": [0.0, 1.0], | |
"cells": [[0, 0, 1, 1]] | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment