harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hinde...@apache.org
Subject svn commit: r929700 - in /harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java: javax/sound/midi/MidiSystem.java org/apache/harmony/sound/internal/nls/messages.properties
Date Wed, 31 Mar 2010 19:55:39 GMT
Author: hindessm
Date: Wed Mar 31 19:55:39 2010
New Revision: 929700

URL: http://svn.apache.org/viewvc?rev=929700&view=rev
Log:
Simple NLS fixes.

Modified:
    harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/javax/sound/midi/MidiSystem.java
    harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/org/apache/harmony/sound/internal/nls/messages.properties

Modified: harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/javax/sound/midi/MidiSystem.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/javax/sound/midi/MidiSystem.java?rev=929700&r1=929699&r2=929700&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/javax/sound/midi/MidiSystem.java
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/javax/sound/midi/MidiSystem.java
Wed Mar 31 19:55:39 2010
@@ -33,6 +33,7 @@ import javax.sound.midi.spi.MidiFileWrit
 import javax.sound.midi.spi.SoundbankReader;
 
 import org.apache.harmony.sound.utils.ProviderService;
+import org.apache.harmony.sound.internal.nls.Messages;
 
 public class MidiSystem {
     // This class has no public constructor
@@ -93,7 +94,7 @@ public class MidiSystem {
         /*
          * if we can't find device with requested info, we throw out IllegalArgumentException
          */
-        throw new IllegalArgumentException("Requested device not installed: " + info.getName());
+        throw new IllegalArgumentException(Messages.getString("sound.1F", info.getName()));
     }
 
     public static MidiDevice.Info[] getMidiDeviceInfo() {
@@ -130,7 +131,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.19"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -152,7 +153,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.19"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -174,7 +175,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.19"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -195,7 +196,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileWriterProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1A"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -216,7 +217,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileWriterProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1A"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -297,7 +298,7 @@ public class MidiSystem {
         /*
          * if we don't find anyway, we throw out MidiUnavailableException
          */
-        throw new MidiUnavailableException("There are no Receivers installed on your system!");
+        throw new MidiUnavailableException(Messages.getString("sound.1B"));
     }
 
     public static Sequence getSequence(File file) throws InvalidMidiDataException, IOException
{
@@ -312,7 +313,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.19"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -334,7 +335,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.19"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -355,7 +356,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.19"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -508,7 +509,7 @@ public class MidiSystem {
         /*
          * if we don't find anyway, we throw out MidiUnavailableException
          */
-        throw new MidiUnavailableException("There are no Synthesizers installed on your system!");
+        throw new MidiUnavailableException(Messages.getString("sound.1C"));
     }
 
     public static Soundbank getSoundbank(File file) throws InvalidMidiDataException,
@@ -524,7 +525,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no SoundbankReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1D"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -545,7 +546,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no SoundbankReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1D"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -566,7 +567,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no SoundbankReaderProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1D"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -648,7 +649,7 @@ public class MidiSystem {
         /*
          * if we don't find anyway, we throw out MidiUnavailableException
          */
-        throw new MidiUnavailableException("There are no Synthesizers installed on your system!");
+        throw new MidiUnavailableException(Messages.getString("sound.1C"));
     }
 
     public static Transmitter getTransmitter() throws MidiUnavailableException {
@@ -723,7 +724,7 @@ public class MidiSystem {
         /*
          * if we don't find anyway, we throw out MidiUnavailableException
          */
-        throw new MidiUnavailableException("There are no Transmitters installed on your system!");
+        throw new MidiUnavailableException(Messages.getString("sound.1E"));
     }
 
     public static boolean isFileTypeSupported(int fileType) {
@@ -739,7 +740,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileWriterProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1A"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -760,7 +761,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileWriterProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1A"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -781,7 +782,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileWriterProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1A"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so
@@ -802,7 +803,7 @@ public class MidiSystem {
              * appropriate providers...
              * Maybe here is should be MidiUnavailableException
              */
-            throw new Error("There is no MidiFileWriterProviders on your system!!!");
+            throw new Error(Messages.getString("sound.1A"));
         }
         /*
          * It's not determine what provider for this service I should to use, and so

Modified: harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/org/apache/harmony/sound/internal/nls/messages.properties
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/org/apache/harmony/sound/internal/nls/messages.properties?rev=929700&r1=929699&r2=929700&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/org/apache/harmony/sound/internal/nls/messages.properties
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/sound/src/main/java/org/apache/harmony/sound/internal/nls/messages.properties
Wed Mar 31 19:55:39 2010
@@ -37,3 +37,10 @@ sound.15=Could not get audio input strea
 sound.16=Could not get audio input stream from input URL
 sound.17=Could not get audio input stream from input file
 sound.18=Type is not supported
+sound.19=There are no MidiFileReaderProviders installed on your system
+sound.1A=There are no MidiFileWriterProviders installed on your system
+sound.1B=There are no Receivers installed on your system
+sound.1C=There are no Synthesizers installed on your system
+sound.1D=There are no SoundbankReaderProviders installed on your system
+sound.1E=There are no Transmitters installed on your system
+sound.1F=Requested device not installed: {0}



Mime
View raw message