/b-gtk/fix-viz

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/b-gtk/fix-viz

« back to all changes in this revision

Viewing changes to __init__.py

  • Committer: David Planella
  • Date: 2010-08-21 09:38:06 UTC
  • mto: This revision was merged to the branch mainline in revision 719.
  • Revision ID: david.planella@ubuntu.com-20100821093806-9u7cq5gcaml6k2ln
Added the rest of files necessary for i18n support in the build system

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
gconflicts        GTK+ conflicts. 
23
23
gdiff             Show differences in working tree in a GTK+ Window. 
24
24
ginit             Initialise a new branch.
25
 
ginfo             GTK+ branch info dialog
26
25
gloom             GTK+ loom browse dialog
27
26
gmerge            GTK+ merge dialog
28
27
gmissing          GTK+ missing revisions dialog. 
59
58
    )
60
59
from bzrlib.commands import plugin_cmds
61
60
 
62
 
 
63
 
version_info = (0, 99, 0, 'dev', 1)
 
61
from info import (
 
62
    bzr_plugin_version as version_info,
 
63
    bzr_compatible_versions,
 
64
    )
64
65
 
65
66
if version_info[3] == 'final':
66
67
    version_string = '%d.%d.%d' % version_info[:3]
68
69
    version_string = '%d.%d.%d%s%d' % version_info
69
70
__version__ = version_string
70
71
 
71
 
COMPATIBLE_BZR_VERSIONS = [(1, 6, 0), (1, 7, 0), (1, 8, 0), (1, 9, 0),
72
 
                           (1, 10, 0), (1, 11, 0), (1, 12, 0), (1, 13, 0),
73
 
                           (1, 15, 0),
74
 
                           (1, 17, 0),
75
 
                           (2, 1, 0),
76
 
                           (2, 2, 0),
77
 
                           ]
78
 
 
79
 
bzrlib.api.require_any_api(bzrlib, COMPATIBLE_BZR_VERSIONS)
 
72
bzrlib.api.require_any_api(bzrlib, bzr_compatible_versions)
80
73
 
81
74
if __name__ != 'bzrlib.plugins.gtk':
82
75
    from bzrlib.trace import warning
135
128
    "gconflicts": [],
136
129
    "gdiff": [],
137
130
    "ginit": [],
138
 
    "ginfo": [],
139
131
    "gmerge": [],
140
132
    "gmissing": [],
141
133
    "gpreferences": [],
166
158
                                       save_commit_messages,
167
159
                                       "Saving commit messages for gcommit")
168
160
 
169
 
import gettext
170
 
gettext.install('olive-gtk')
171
 
 
172
 
# Let's create a specialized alias to protect '_' from being erased by other
173
 
# uses of '_' as an anonymous variable (think pdb for one).
174
 
_i18n = gettext.gettext
175
 
 
176
161
class NoDisplayError(errors.BzrCommandError):
177
162
    """gtk could not find a proper display"""
178
163
 
212
197
            reload(sys)
213
198
            sys.setdefaultencoding(default_encoding)
214
199
    return basic_tests
 
200
 
 
201
 
 
202
def _i18n(text):
 
203
    # Stub until we support proper i18n
 
204
    return text