blob: 4c928141e8f8433f8f8b23796a1f437d2d736af7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
#!/usr/bin/env python
#-*- coding:utf-8 -*-
# Copyright 2009 Matthieu Gautier
# This file is part of g-ed-it.
#
# g-ed-it is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# any later version.
#
# g-ed-it is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with g-ed-it. If not, see <http://www.gnu.org/licenses/>.
import gedit
import os
import os.path
import windowHelper
import gitAction
class G_ed_it(gedit.Plugin):
def __init__(self):
gedit.Plugin.__init__(self)
self.windowHelpers = {}
self.gitAction = gitAction.GitAction(self)
def activate(self, window):
self.windowHelpers[window] = windowHelper.WindowHelper(self, window, self.gitAction)
def deactivate(self, window):
self.windowHelpers[window].deactivate()
def update_ui(self, window):
self.windowHelpers[window].update_ui()
def fast_update_ui(self):
for windowHelper in self.windowHelpers :
self.windowHelpers[windowHelper].fast_update_ui()
|