Skip to content

Instantly share code, notes, and snippets.

@uzysjung
Created November 11, 2014 07:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save uzysjung/e5cad519913643701308 to your computer and use it in GitHub Desktop.
Save uzysjung/e5cad519913643701308 to your computer and use it in GitHub Desktop.
//
// NSLocale+ios8_1.m
//
// Created by Uzysjung on 2014. 11. 11..
// Copyright (c) 2014년 SKPlanet. All rights reserved.
//
#if TARGET_IPHONE_SIMULATOR
#import "NSLocale+ios8_1.h"
#import <objc/runtime.h>
@implementation NSLocale (iOS8_1)
+ (void)load
{
Method originalMethod = class_getClassMethod(self, @selector(currentLocale));
Method swizzledMethod = class_getClassMethod(self, @selector(swizzle_currentLocale));
method_exchangeImplementations(originalMethod, swizzledMethod);
}
+ (NSLocale*)swizzle_currentLocale
{
return [NSLocale localeWithLocaleIdentifier:@"ko_KR"];
}
@end
#endif
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment