plugin/threesome.py @ c353930abfc4 v0.0.1

Quitting keys.
author Steve Losh <steve@stevelosh.com>
date Mon, 13 Jun 2011 01:07:55 -0400
parents 890a1d687c33
children 2358d83d3830
import vim, os, sys


# Add the library to the Python path.
for p in vim.eval("&runtimepath").split(','):
   plugin_dir = os.path.join(p, "plugin")
   if os.path.exists(os.path.join(plugin_dir, "threesomelib")):
      if plugin_dir not in sys.path:
         sys.path.append(plugin_dir)
      break


# Wrapper functions
threesome = None
def ThreesomeInit():
    global threesome
    import threesomelib.init as init
    init.init()
    threesome = init


def ThreesomeOriginal():
    threesome.modes.current_mode.key_original()

def ThreesomeOne():
    threesome.modes.current_mode.key_one()

def ThreesomeTwo():
    threesome.modes.current_mode.key_two()

def ThreesomeResult():
    threesome.modes.current_mode.key_result()


def ThreesomeGrid():
    threesome.modes.key_grid()

def ThreesomeLoupe():
    threesome.modes.key_loupe()

def ThreesomeCompare():
    threesome.modes.key_compare()

def ThreesomePath():
    threesome.modes.key_path()


def ThreesomeDiff():
    threesome.modes.current_mode.key_diff()

def ThreesomeDiffoff():
    threesome.modes.current_mode.key_diffoff()

def ThreesomeNext():
    threesome.modes.current_mode.key_next()

def ThreesomePrev():
    threesome.modes.current_mode.key_prev()