OSX refactor -> renamed OSXWindowFrameView to OSXView

This commit is contained in:
Carlos Aragones
2020-05-17 18:39:51 +02:00
parent 235dc1e670
commit 75de20e4cc
6 changed files with 13 additions and 12 deletions

View File

@ -1,5 +1,5 @@
#include "OSXWindow.h"
#include "OSXWindowFrameView.h"
#include "OSXView.h"
#include "OSXViewController.h"
#include "WindowData_OSX.h"
#include <MiniFB.h>

View File

@ -2,7 +2,7 @@
#include "WindowData.h"
@interface OSXWindowFrameView : NSView
@interface OSXView : NSView
{
@public SWindowData *window_data;
#if defined(USE_METAL_API)

View File

@ -1,9 +1,9 @@
#import "OSXWindowFrameView.h"
#import "OSXView.h"
#import "OSXWindow.h"
#include <MiniFB_internal.h>
//-------------------------------------
@implementation OSXWindowFrameView
@implementation OSXView
#if defined(USE_METAL_API)

View File

@ -1,5 +1,5 @@
#import "OSXWindow.h"
#import "OSXWindowFrameView.h"
#import "OSXView.h"
#include "WindowData_OSX.h"
#include <MiniFB_internal.h>
#include <MiniFB_enums.h>
@ -28,7 +28,7 @@
self.delegate = self;
self->window_data = windowData;
OSXWindowFrameView *view = (OSXWindowFrameView *) self->childContentView.superview;
OSXView *view = (OSXView *) self->childContentView.superview;
view->window_data = windowData;
}
return self;
@ -38,7 +38,7 @@
- (void) removeWindowData {
self->window_data = 0x0;
OSXWindowFrameView *view = (OSXWindowFrameView *) self->childContentView.superview;
OSXView *view = (OSXView *) self->childContentView.superview;
view->window_data = 0x0;
}
@ -60,7 +60,7 @@
sizeDelta.width -= childBoundsSize.width;
sizeDelta.height -= childBoundsSize.height;
OSXWindowFrameView *frameView = [super contentView];
OSXView *frameView = [super contentView];
NSSize newFrameSize = [frameView bounds].size;
newFrameSize.width += sizeDelta.width;
newFrameSize.height += sizeDelta.height;
@ -208,10 +208,10 @@
NSRect bounds = [self frame];
bounds.origin = NSZeroPoint;
OSXWindowFrameView *frameView = [super contentView];
OSXView *frameView = [super contentView];
if (!frameView)
{
frameView = [[[OSXWindowFrameView alloc] initWithFrame:bounds] autorelease];
frameView = [[[OSXView alloc] initWithFrame:bounds] autorelease];
[super setContentView:frameView];
}