Skip to content
This repository has been archived by the owner on Mar 30, 2021. It is now read-only.

Commit

Permalink
Merge pull request #537 from radiant-player/fix-search-bar
Browse files Browse the repository at this point in the history
Fix search box issues on El Capitan
  • Loading branch information
jacobwgillespie committed Apr 4, 2016
2 parents f66c445 + 12f8ba3 commit 82900db
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 1 deletion.
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@ This file should follow the standards specified on [keepachangelog.com](http://k
This project adheres to [Semantic Versioning](http://semver.org/).

## [unreleased]
### Fixed
* Fixed search box UI issues for El Capitan users ([#537](https://github.com/radiant-player/radiant-player-mac/pull/537), [@BarakaAka1Only](https://github.com/BarakaAka1Only))

## [1.8.1] - 2016-04-02

### Fixed
* Fixed UI issues for Mavericks users ([#534](https://github.com/radiant-player/radiant-player-mac/pull/534), [@BarakaAka1Only](https://github.com/BarakaAka1Only))

## [1.8.0] - 2016-03-30
Expand Down
1 change: 1 addition & 0 deletions radiant-player-mac/AppDelegate.h
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@
- (void) ratingChanged:(NSInteger)rating;

- (id) preferenceForKey:(NSString *)key;
- (BOOL) isElCapitan;
- (BOOL) isYosemite;
- (BOOL) isMavericks;

Expand Down
11 changes: 11 additions & 0 deletions radiant-player-mac/AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -930,10 +930,16 @@ - (void)webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame
// Apply common styles.
[self applyCSSFile:@"common"];

// Apply flexbox fix for Yosemite and Mavericks
if ([self isYosemite] || [self isMavericks]) {
[self applyCSSFile:@"flexfix"];
}

// Apply zindex fix for El Capitan
if ([self isElCapitan]) {
[self applyCSSFile:@"zindex"];
}

// Apply the navigation styles.
[self applyCSSFile:@"navigation"];
[self evaluateJavaScriptFile:@"navigation"];
Expand Down Expand Up @@ -979,6 +985,11 @@ - (id)preferenceForKey:(NSString *)key
return nil;
}

- (BOOL)isElCapitan
{
return floor(NSAppKitVersionNumber) > NSAppKitVersionNumber10_10_Max;
}

- (BOOL)isYosemite
{
return floor(NSAppKitVersionNumber) > NSAppKitVersionNumber10_9;
Expand Down
5 changes: 5 additions & 0 deletions radiant-player-mac/css/zindex.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/* z-index fix for El Capitan */

#material-one-middle {
z-index: 1;
}

0 comments on commit 82900db

Please sign in to comment.