• R/O
  • SSH
  • HTTPS

Commit

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

OmegaT の背景に画像を表示します。


Commit MetaInfo

Revision4 (tree)
Time2013-08-07 00:49:23
Authoryu-tang

Log Message

デバッグ用のコードを削除

Change Summary

Incremental Difference

--- trunk/src/org/omegat/plugin/moenizer/MoeConfig.java (revision 3)
+++ trunk/src/org/omegat/plugin/moenizer/MoeConfig.java (revision 4)
@@ -101,9 +101,7 @@
101101 if ( file.isFile() ) {
102102 String text = FileUtil.readTextFile(file);
103103 String[] lines = RE_LINEBREAK.split(text);
104- Log.log("---- Config lines start ----");
105104 for (String line: lines) {
106- Log.log("[" + line + "]");
107105 if ( ! line.isEmpty() ) {
108106 if (setOpacity(data, line) == true) {
109107 // probably opacity value is changed from default
@@ -118,9 +116,7 @@
118116 }
119117 }
120118 }
121- Log.log("---- Config lines end ----");
122119 } else {
123- Log.log("Config file '" + CONFIG_FILE_NAME + "' is not found.");
124120 }
125121 } catch (Exception ex) {
126122 Log.log(ex);
@@ -147,18 +143,14 @@
147143 Matcher matcher = RE_OPACITY.matcher(line);
148144 if ( matcher.matches() ) {
149145 String num = matcher.group(1);
150- Log.log("new Opacity (String) = " + num + "%");
151146 int i = Integer.parseInt(num); // in percent
152147 if (i > MAX_OPACITY_IN_PERCENTAGE) {
153- Log.log("value '" + line + "' is out of range for opacity.");
154148 data.opacity = MAX_OPACITY_IN_PERCENTAGE;
155149 } else if (i < MIN_OPACITY_IN_PERCENTAGE) {
156- Log.log("value '" + line + "' is out of range for opacity.");
157150 data.opacity = MIN_OPACITY_IN_PERCENTAGE;
158151 } else {
159152 float f = ((float) i / MAX_OPACITY_IN_PERCENTAGE);
160153 data.opacity = f;
161- Log.log("new Opacity (float) = " + f);
162154 }
163155 return true;
164156 }
@@ -176,7 +168,6 @@
176168 if ( matcher.matches() ) {
177169 String num = matcher.group(1);
178170 String unit = matcher.group(2).toLowerCase(); // s | m | h
179- Log.log("new Interval (String) = " + num + unit);
180171
181172 long i = Long.parseLong(num);
182173 if (unit.equals("s")) {
@@ -189,14 +180,11 @@
189180
190181 // validate range
191182 if (i > MAX_INTERVAL) {
192- Log.log("value '" + line + "' is out of range for interval.");
193183 data.interval = MAX_INTERVAL;
194184 } else if (i < MIN_INTERVAL) {
195- Log.log("value '" + line + "' is out of range for interval.");
196185 data.interval = MIN_INTERVAL;
197186 } else {
198187 data.interval = i;
199- Log.log("new Interval (int) = " + i);
200188 }
201189 return true;
202190 }
@@ -213,7 +201,6 @@
213201 Matcher matcher = RE_SCRIPT.matcher(line);
214202 if ( matcher.matches() ) {
215203 data.script = line;
216- Log.log("new script = " + line);
217204 return true;
218205 }
219206 return false;
@@ -256,7 +243,6 @@
256243 public boolean accept(File f) {
257244 if (f.isFile()) {
258245 String fileName = f.getName().toLowerCase();
259- Log.log("fileName is " + fileName);
260246 if (RE_HAS_IMAGE_EXTENSION.matcher(fileName).matches() ||
261247 RE_HAS_INTERNET_SHORTCUT_EXTENSION.matcher(fileName).matches()) {
262248 return true;
@@ -306,7 +292,6 @@
306292 public boolean accept(File f) {
307293 if (f.isFile()) {
308294 String fileName = f.getName().toLowerCase();
309- Log.log("fileName is " + fileName);
310295 if (RE_SOURCE_IN_PLUGIN_DIR.matcher(fileName).matches()) {
311296 return true;
312297 }
@@ -316,7 +301,6 @@
316301 });
317302 for (File f: listFiles) {
318303 String fileName = f.getName().toLowerCase();
319- Log.log("LowerCaseFileName:" + fileName);
320304 // image file
321305 if (RE_HAS_IMAGE_EXTENSION.matcher(fileName).matches()) {
322306 newSource.add(f);
@@ -323,7 +307,6 @@
323307 // internet shortcut
324308 } else if (RE_HAS_INTERNET_SHORTCUT_EXTENSION.matcher(fileName).matches()) {
325309 URL url = MoeUtil.getURL(f);
326- Log.log(url == null ? "URL is NULL!!" : "URL is not null: " + url.toExternalForm());
327310 if (url != null) {
328311 newSource.add(url);
329312 }
--- trunk/src/org/omegat/plugin/moenizer/Moenizer.java (revision 3)
+++ trunk/src/org/omegat/plugin/moenizer/Moenizer.java (revision 4)
@@ -73,20 +73,6 @@
7373 } catch(Exception e) {
7474 Log.log("Error raised at " + this.getClass().getCanonicalName() + ".onApplicationStartup()\n" + e);
7575 }
76-
77-
78- try {
79- // ちょっとテストしますよ。
80- Log.log("NTP: " + StaticUtils.downloadFileToString("http://ntp-a1.nict.go.jp/cgi-bin/time"));
81- // Sun Jul 14 02:24:16 2013 JST
82- } catch (IOException ex) {
83- Logger.getLogger(Moenizer.class.getName()).log(Level.SEVERE, null, ex);
84- }
85-
86-
87-
88-
89-
9076 }
9177
9278 @Override
--- trunk/src/org/omegat/plugin/moenizer/imageloader/ImageLoader.java (revision 3)
+++ trunk/src/org/omegat/plugin/moenizer/imageloader/ImageLoader.java (revision 4)
@@ -35,7 +35,6 @@
3535 }
3636
3737 // default
38- Log.log("DefaultImageLoader will use.");
3938 return new DefaultImageLoader();
4039 }
4140
--- trunk/src/org/omegat/plugin/moenizer/imageloader/DefaultImageLoader.java (revision 3)
+++ trunk/src/org/omegat/plugin/moenizer/imageloader/DefaultImageLoader.java (revision 4)
@@ -93,7 +93,6 @@
9393 */
9494 @Override
9595 public BufferedImage getNextImage() {
96- Log.log("getNextImage() called.");
9796 return image;
9897 }
9998
@@ -103,19 +102,15 @@
103102 */
104103 @Override
105104 public void readyForNextImage() {
106- Log.log("readyForNextImage() called.");
107105 //TODO use cache
108106 image = null;
109107 try {
110108 if (currentSource != null) {
111109 if (currentSource instanceof File) {
112- Log.log("File = " + ((File) currentSource).getCanonicalPath());
113110 image = ImageIO.read((File) currentSource);
114111 } else if (currentSource instanceof URL) {
115- Log.log("File = " + ((URL) currentSource).toExternalForm());
116112 image = ImageIO.read((URL) currentSource);
117113 } else {
118- Log.log("Unknown source type:" + currentSource.getClass().getCanonicalName());
119114 removeCurrentSource();
120115 }
121116 }
@@ -140,7 +135,6 @@
140135 if (sourceIndex >= sources.length) {
141136 sourceIndex = 0;
142137 }
143- Log.log("getCircularNextSource(): " + sources[sourceIndex].getClass().getCanonicalName());
144138 return sources[sourceIndex];
145139 }
146140