Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

First version with support for Spanish and French

  • Loading branch information...
commit a986a50b6c05b5cc486ab8bf840fca119a2c072f 1 parent 94000db
Adrian Kosmaczewski authored
13 Classes/BluewokiAppDelegate.m
View
@@ -45,7 +45,7 @@ - (void)applicationDidFinishLaunching:(UIApplication *)application
AudioSessionSetActive(true);
[GKVoiceChatService defaultVoiceChatService].client = self;
- statusLabel.text = @"ready";
+ statusLabel.text = NSLocalizedString(@"ready", @"Used when the application starts and after the peer disconnects");
}
- (void)dealloc
@@ -95,7 +95,8 @@ - (void)peerPickerController:(GKPeerPickerController *)picker didConnectPeer:(NS
[[GKVoiceChatService defaultVoiceChatService] startVoiceChatWithParticipantID:peerID
error:nil];
- statusLabel.text = [NSString stringWithFormat:@"connected with\n%@", [chatSession displayNameForPeer:peerID]];
+ statusLabel.text = [NSString stringWithFormat:NSLocalizedString(@"connected with", @"Shows who we're talking to"),
+ [chatSession displayNameForPeer:peerID]];
[UIApplication sharedApplication].idleTimerDisabled = YES;
[UIDevice currentDevice].proximityMonitoringEnabled = YES;
connectButton.enabled = NO;
@@ -125,11 +126,11 @@ - (void)session:(GKSession *)session peer:(NSString *)peerID didChangeState:(GKP
break;
case GKPeerStateDisconnected:
- [self closeConnectionWithMessage:@"peer disconnected"];
+ [self closeConnectionWithMessage:NSLocalizedString(@"peer disconnected", @"Shown when the other user disconnects")];
break;
case GKPeerStateConnecting:
- statusLabel.text = @"connecting";
+ statusLabel.text = NSLocalizedString(@"connecting", @"Shown while the connection is negotiated");
break;
default:
@@ -142,7 +143,7 @@ - (void)session:(GKSession *)session connectionWithPeerFailed:(NSString *)peerID
{
if (session == chatSession)
{
- [self closeConnectionWithMessage:@"error"];
+ [self closeConnectionWithMessage:NSLocalizedString(@"error", @"Shown when the connection generated an error")];
}
}
@@ -185,7 +186,7 @@ - (void)closeConnectionWithMessage:(NSString *)message
- (void)resetInterface
{
- statusLabel.text = @"ready";
+ statusLabel.text = NSLocalizedString(@"ready", @"Used when the application starts and after the peer disconnects");
}
@end
BIN  Resources/Strings/en.lproj/Localizable.strings
View
Binary file not shown
BIN  Resources/Strings/es.lproj/Localizable.strings
View
Binary file not shown
BIN  Resources/Strings/fr.lproj/Localizable.strings
View
Binary file not shown
37 bluewoki.xcodeproj/project.pbxproj
View
@@ -19,6 +19,7 @@
3A5FBAF80FF8B0D50060478C /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 3A5FBAF60FF8B0D50060478C /* Default.png */; };
3A5FBAF90FF8B0D50060478C /* Icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 3A5FBAF70FF8B0D50060478C /* Icon.png */; };
3AF6C9450FF8B7F000312D0A /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 3AF6C9440FF8B7F000312D0A /* MainWindow.xib */; };
+ 3AF6F7100FF8D9590083EA15 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = 3AF6F70E0FF8D9590083EA15 /* Localizable.strings */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
@@ -37,6 +38,9 @@
3A5FBAF60FF8B0D50060478C /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
3A5FBAF70FF8B0D50060478C /* Icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Icon.png; sourceTree = "<group>"; };
3AF6C9440FF8B7F000312D0A /* MainWindow.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = MainWindow.xib; sourceTree = "<group>"; };
+ 3AF6F70F0FF8D9590083EA15 /* en */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/Localizable.strings; sourceTree = "<group>"; };
+ 3AF6F7140FF8D9C40083EA15 /* es */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = es; path = es.lproj/Localizable.strings; sourceTree = "<group>"; };
+ 3AF6F7150FF8D9D60083EA15 /* fr */ = {isa = PBXFileReference; fileEncoding = 10; lastKnownFileType = text.plist.strings; name = fr; path = fr.lproj/Localizable.strings; sourceTree = "<group>"; };
8D1107310486CEB800E47090 /* bluewoki-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "bluewoki-Info.plist"; path = "../bluewoki-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = "<group>"; };
/* End PBXFileReference section */
@@ -102,6 +106,7 @@
3A22AD4C0FF8ACC100E867BE /* Resources */ = {
isa = PBXGroup;
children = (
+ 3AF6F70D0FF8D93C0083EA15 /* Strings */,
3AF6C9430FF8B7F000312D0A /* NIBs */,
3A5FBAF50FF8B0D50060478C /* Images */,
8D1107310486CEB800E47090 /* bluewoki-Info.plist */,
@@ -136,6 +141,14 @@
path = NIBs;
sourceTree = "<group>";
};
+ 3AF6F70D0FF8D93C0083EA15 /* Strings */ = {
+ isa = PBXGroup;
+ children = (
+ 3AF6F70E0FF8D9590083EA15 /* Localizable.strings */,
+ );
+ path = Strings;
+ sourceTree = "<group>";
+ };
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
@@ -164,6 +177,16 @@
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "bluewoki" */;
compatibilityVersion = "Xcode 3.1";
hasScannedForEncodings = 1;
+ knownRegions = (
+ English,
+ Japanese,
+ French,
+ German,
+ fr,
+ Spanish,
+ en,
+ es,
+ );
mainGroup = 29B97314FDCFA39411CA2CEA /* CustomTemplate */;
projectDirPath = "";
projectRoot = "";
@@ -182,6 +205,7 @@
3A5FBAF80FF8B0D50060478C /* Default.png in Resources */,
3A5FBAF90FF8B0D50060478C /* Icon.png in Resources */,
3AF6C9450FF8B7F000312D0A /* MainWindow.xib in Resources */,
+ 3AF6F7100FF8D9590083EA15 /* Localizable.strings in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -199,6 +223,19 @@
};
/* End PBXSourcesBuildPhase section */
+/* Begin PBXVariantGroup section */
+ 3AF6F70E0FF8D9590083EA15 /* Localizable.strings */ = {
+ isa = PBXVariantGroup;
+ children = (
+ 3AF6F70F0FF8D9590083EA15 /* en */,
+ 3AF6F7140FF8D9C40083EA15 /* es */,
+ 3AF6F7150FF8D9D60083EA15 /* fr */,
+ );
+ name = Localizable.strings;
+ sourceTree = "<group>";
+ };
+/* End PBXVariantGroup section */
+
/* Begin XCBuildConfiguration section */
1D6058940D05DD3E006BFB54 /* Debug */ = {
isa = XCBuildConfiguration;
2  main.m
View
@@ -3,7 +3,7 @@
// bluewoki
//
// Created by Adrian on 6/29/09.
-// Copyright __MyCompanyName__ 2009. All rights reserved.
+// Copyright akosma software 2009. All rights reserved.
//
#import <UIKit/UIKit.h>
Please sign in to comment.
Something went wrong with that request. Please try again.