cleanup some warnings in cocoa frontend

This commit is contained in:
Vincent Sanders 2016-05-02 13:12:43 +01:00
parent 99299845e7
commit d8d0ad3b49
4 changed files with 33 additions and 26 deletions

View File

@ -156,12 +156,6 @@ static NSRect ScreenRectForView( NSView *view )
NSPoint arrowPoint;
switch ([box arrowEdge]) {
case ArrowNone:
case ArrowTopEdge:
arrowPoint = NSMakePoint( NSMidX( viewRect ),
NSMinY( viewRect ) );
break;
case ArrowLeftEdge:
arrowPoint = NSMakePoint( NSMaxX( viewRect ),
NSMidY( viewRect ) );
@ -176,6 +170,14 @@ static NSRect ScreenRectForView( NSView *view )
arrowPoint = NSMakePoint( NSMinX( viewRect ),
NSMidY( viewRect ) );
break;
case ArrowNone:
case ArrowTopEdge:
default:
arrowPoint = NSMakePoint( NSMidX( viewRect ),
NSMinY( viewRect ) );
break;
}
attachedWindow = [view window];
[self moveToPoint: arrowPoint];

View File

@ -16,6 +16,14 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#import "utils/nsoption.h"
#import "utils/messages.h"
#import "desktop/browser.h"
#import "desktop/plotters.h"
#import "desktop/textinput.h"
#import "content/hlcache.h"
#import "cocoa/gui.h"
#import "cocoa/BrowserView.h"
#import "cocoa/HistoryView.h"
#import "cocoa/font.h"
@ -23,12 +31,6 @@
#import "cocoa/LocalHistoryController.h"
#import "cocoa/BrowserWindowController.h"
#import "desktop/browser.h"
#import "desktop/plotters.h"
#import "desktop/textinput.h"
#import "utils/nsoption.h"
#import "utils/messages.h"
#import "content/hlcache.h"
@interface BrowserView ()

View File

@ -16,23 +16,24 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#import "cocoa/BrowserViewController.h"
#import "cocoa/BrowserView.h"
#import "cocoa/BrowserWindowController.h"
#import "cocoa/fetch.h"
#import "desktop/browser_history.h"
#import "desktop/browser.h"
#import "desktop/textinput.h"
#import "utils/nsoption.h"
#import "utils/corestrings.h"
#import "utils/filename.h"
#import "utils/file.h"
#import "utils/messages.h"
#import "utils/url.h"
#import "desktop/browser_history.h"
#import "desktop/browser.h"
#import "desktop/textinput.h"
#import "content/hlcache.h"
#import "cocoa/gui.h"
#import "cocoa/BrowserViewController.h"
#import "cocoa/BrowserView.h"
#import "cocoa/BrowserWindowController.h"
#import "cocoa/fetch.h"
@implementation BrowserViewController

View File

@ -16,16 +16,18 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#import "utils/nsoption.h"
#import "utils/messages.h"
#import "utils/utils.h"
#import "utils/nsurl.h"
#import "desktop/browser.h"
#import "cocoa/gui.h"
#import "cocoa/NetSurfAppDelegate.h"
#import "cocoa/SearchWindowController.h"
#import "cocoa/PreferencesWindowController.h"
#import "cocoa/HistoryWindowController.h"
#import "desktop/browser.h"
#import "utils/nsoption.h"
#import "utils/messages.h"
#import "utils/utils.h"
#import "utils/nsurl.h"
@interface NetSurfAppDelegate ()