-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Mac: Implement Retina for the 3D scene, fix #97
- Loading branch information
1 parent
54bd2e5
commit 4081d13
Showing
11 changed files
with
421 additions
and
89 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#ifndef slic3r_RetinaHelper_hpp_ | ||
#define slic3r_RetinaHelper_hpp_ | ||
|
||
class wxWindow; | ||
|
||
|
||
namespace Slic3r { | ||
namespace GUI { | ||
|
||
class RetinaHelper | ||
{ | ||
public: | ||
RetinaHelper(wxWindow* window); | ||
~RetinaHelper(); | ||
|
||
void set_use_retina(bool value); | ||
bool get_use_retina(); | ||
float get_scale_factor(); | ||
|
||
private: | ||
wxWindow* m_window; | ||
void* m_self; | ||
}; | ||
|
||
|
||
} // namespace GUI | ||
} // namespace Slic3r | ||
|
||
#endif // RetinaHelper_h |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#import <Cocoa/Cocoa.h> | ||
|
||
class wxEvtHandler; | ||
|
||
@interface RetinaHelperImpl : NSObject | ||
{ | ||
NSView *view; | ||
wxEvtHandler* handler; | ||
} | ||
|
||
-(id)initWithView:(NSView *)view handler:(wxEvtHandler *)handler; | ||
-(void)setViewWantsBestResolutionOpenGLSurface:(BOOL)value; | ||
-(BOOL)getViewWantsBestResolutionOpenGLSurface; | ||
-(float)getBackingScaleFactor; | ||
@end |
Oops, something went wrong.