Replace use of simplejson - SL #4487
Signed-off-by: Gonzalo Odiard <gonzalo@laptop.org>
Gonzalo Odiard
10 years ago
14 | 14 | # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA |
15 | 15 | |
16 | 16 | import os |
17 | import simplejson | |
17 | import json | |
18 | 18 | from gettext import gettext as _ |
19 | 19 | |
20 | 20 | from gi.repository import Gtk |
94 | 94 | if os.path.exists(data_file_name): |
95 | 95 | f = open(data_file_name, 'r') |
96 | 96 | try: |
97 | speech_parameters = simplejson.load(f) | |
97 | speech_parameters = json.load(f) | |
98 | 98 | speech.voice = speech_parameters['voice'] |
99 | 99 | finally: |
100 | 100 | f.close() |
123 | 123 | data_file_name = os.path.join(data_path, 'speech_params.json') |
124 | 124 | f = open(data_file_name, 'w') |
125 | 125 | try: |
126 | simplejson.dump(speech_parameters, f) | |
126 | json.dump(speech_parameters, f) | |
127 | 127 | finally: |
128 | 128 | f.close() |
129 | 129 |