Skip to content

Instantly share code, notes, and snippets.

@adib
Created June 13, 2014 13:08
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 adib/d8a1ea377949c4d36cc9 to your computer and use it in GitHub Desktop.
Save adib/d8a1ea377949c4d36cc9 to your computer and use it in GitHub Desktop.
//
// BSGLView.h
// AirKill
//
// Created by Sasmito Adibowo on 07-06-14.
// Basil Salad Software, http://basilsalad.com
//
// This code is in the public domain.
#import "CCGLView.h"
@interface BSGLView : CCGLView
@end
//
// BSGLView.m
// AirKill
//
// Created by Sasmito Adibowo on 07-06-14.
// Basil Salad Software, http://basilsalad.com
//
// This code is in the public domain.
//
#import <objc/message.h>
#import "BSGLView.h"
@implementation BSGLView
-(void)layoutSubviews
{
// We need this because CCGLView doesn't call UIView layoutSubviews and we need to add subviews
Class granny = [[self superclass] superclass];
struct objc_super theSuper = {self, granny};
objc_msgSendSuper(&theSuper,_cmd);
[super layoutSubviews];
}
@end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment