Re: [hatari-devel] Resizable.

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Hi
Resizable button runs as you said ! Diff is below.
Regards
   Miguel

diff -r f1c3f40e7e88 src/gui-osx/PrefsController.h
--- a/src/gui-osx/PrefsController.h	Tue Jun 20 21:35:02 2017 +0300
+++ b/src/gui-osx/PrefsController.h	Sat Jun 24 20:51:57 2017 +0200
@@ -57,7 +57,8 @@
 	IBOutlet NSTextField *maxZoomedHeight;				// N
 	IBOutlet NSButton *keepDesktopResolution;
 	IBOutlet NSButton *SDL2UseLinearScaling;
-	IBOutlet NSButton *SDL2UseVSync;
+	IBOutlet NSButton *SDL2Resizable ;
+	IBOutlet NSButton *SDL2UseVSync ;
 
 	// Hidestatus, Capture only, Avi codec, Avi FPS
 	// Sound
diff -r f1c3f40e7e88 src/gui-osx/PrefsController.m
--- a/src/gui-osx/PrefsController.m	Tue Jun 20 21:35:02 2017 +0300
+++ b/src/gui-osx/PrefsController.m	Sat Jun 24 20:51:57 2017 +0200
@@ -10,6 +10,7 @@
   Jan 2006, Sébastien Molines - Updated for recent emulator updates
   2013 : Miguel SARO, J. VERNET
   2016 : J. VERNET - Updated for 1.9.0
+  2017 : Miguel SARO resizable
 */
 
 // bOKDialog = Dialog_MainDlg(&bForceReset, &bLoadedSnapshot);   // prise des préférences
@@ -744,6 +745,7 @@
 
 	//1.9.0 SDL2
 	IMPORT_SWITCH(SDL2UseLinearScaling, ConfigureParams.Screen.nRenderScaleQuality);
+	IMPORT_SWITCH(SDL2Resizable, ConfigureParams.Screen.bResizable) ;				// MS 06-2017
 	IMPORT_SWITCH(SDL2UseVSync, ConfigureParams.Screen.bUseVsync);
 
 	//deal with the Max Zoomed Stepper
@@ -1010,6 +1012,7 @@
 	EXPORT_RADIO(YMVoicesMixing,ConfigureParams.Sound.YmVolumeMixing);
 	//1.9.0 SDL2
 	EXPORT_SWITCH(SDL2UseLinearScaling, ConfigureParams.Screen.nRenderScaleQuality);
+	EXPORT_SWITCH(SDL2Resizable, ConfigureParams.Screen.bResizable) ;					// MS 06-2017
 	EXPORT_SWITCH(SDL2UseVSync, ConfigureParams.Screen.bUseVsync);
 
 	EXPORT_NTEXTFIELD(maxZoomedWidth, ConfigureParams.Screen.nMaxWidth);
diff -r f1c3f40e7e88 src/gui-osx/en.lproj/SDLMain.xib
--- a/src/gui-osx/en.lproj/SDLMain.xib	Tue Jun 20 21:35:02 2017 +0300
+++ b/src/gui-osx/en.lproj/SDLMain.xib	Sat Jun 24 20:51:57 2017 +0200
@@ -1200,22 +1200,30 @@
                                                 <rect key="frame" x="1" y="1" width="604" height="74"/>
                                                 <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
                                                 <subviews>
-                                                    <button id="uX5-95-dj6">
-                                                        <rect key="frame" x="18" y="38" width="135" height="18"/>
+                                                    <button misplaced="YES" id="uX5-95-dj6">
+                                                        <rect key="frame" x="18" y="51" width="145" height="18"/>
                                                         <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
                                                         <buttonCell key="cell" type="check" title="Use Linear Scaling" bezelStyle="regularSquare" imagePosition="left" inset="2" id="f9y-RU-qCj">
                                                             <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                                                             <font key="font" metaFont="system"/>
                                                         </buttonCell>
                                                     </button>
-                                                    <button id="8G1-GF-0DS">
-                                                        <rect key="frame" x="18" y="18" width="88" height="18"/>
+                                                    <button misplaced="YES" id="8G1-GF-0DS">
+                                                        <rect key="frame" x="18" y="12" width="145" height="18"/>
                                                         <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
                                                         <buttonCell key="cell" type="check" title="Use VSync" bezelStyle="regularSquare" imagePosition="left" inset="2" id="3qq-3C-dcy">
                                                             <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                                                             <font key="font" metaFont="system"/>
                                                         </buttonCell>
                                                     </button>
+                                                    <button misplaced="YES" id="I7I-1M-5Nu">
+                                                        <rect key="frame" x="18" y="31" width="145" height="18"/>
+                                                        <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+                                                        <buttonCell key="cell" type="check" title="Resizable" bezelStyle="regularSquare" imagePosition="left" state="on" inset="2" id="uLm-5c-ptb">
+                                                            <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
+                                                            <font key="font" metaFont="system"/>
+                                                        </buttonCell>
+                                                    </button>
                                                 </subviews>
                                             </view>
                                         </box>
@@ -2390,6 +2398,7 @@
                 <outlet property="FastBootPatch" destination="4718" id="4734"/>
                 <outlet property="HDWriteProtection" destination="4668" id="4681"/>
                 <outlet property="MMU_Emulation" destination="aWS-WS-f9G" id="eop-C7-jO5"/>
+                <outlet property="SDL2Resizable" destination="I7I-1M-5Nu" id="AVS-08-eZu"/>
                 <outlet property="SDL2UseLinearScaling" destination="uX5-95-dj6" id="5wO-9c-XNe"/>
                 <outlet property="SDL2UseVSync" destination="8G1-GF-0DS" id="qsx-Ol-6G0"/>
                 <outlet property="TTRAMSizeStepper" destination="5kN-DE-Lud" id="5bu-Xe-D9P"/>
diff -r f1c3f40e7e88 src/gui-osx/fr.lproj/SDLMain.xib
--- a/src/gui-osx/fr.lproj/SDLMain.xib	Tue Jun 20 21:35:02 2017 +0300
+++ b/src/gui-osx/fr.lproj/SDLMain.xib	Sat Jun 24 20:51:57 2017 +0200
@@ -1233,22 +1233,30 @@
                                                 <rect key="frame" x="1" y="1" width="604" height="74"/>
                                                 <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
                                                 <subviews>
-                                                    <button id="Sco-Iv-wnc">
-                                                        <rect key="frame" x="18" y="38" width="135" height="18"/>
+                                                    <button misplaced="YES" id="Sco-Iv-wnc">
+                                                        <rect key="frame" x="18" y="52" width="135" height="18"/>
                                                         <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
                                                         <buttonCell key="cell" type="check" title="Use Linear Scaling" bezelStyle="regularSquare" imagePosition="left" inset="2" id="TdS-TX-oGj">
                                                             <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                                                             <font key="font" metaFont="system"/>
                                                         </buttonCell>
                                                     </button>
-                                                    <button id="Hti-Yj-SZa">
-                                                        <rect key="frame" x="18" y="18" width="88" height="18"/>
+                                                    <button misplaced="YES" id="Hti-Yj-SZa">
+                                                        <rect key="frame" x="18" y="4" width="88" height="18"/>
                                                         <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
                                                         <buttonCell key="cell" type="check" title="Use VSync" bezelStyle="regularSquare" imagePosition="left" inset="2" id="wLX-Os-YkN">
                                                             <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                                                             <font key="font" metaFont="system"/>
                                                         </buttonCell>
                                                     </button>
+                                                    <button misplaced="YES" id="6Qc-ZR-WJc">
+                                                        <rect key="frame" x="18" y="28" width="162" height="18"/>
+                                                        <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+                                                        <buttonCell key="cell" type="check" title="Resizable" bezelStyle="regularSquare" imagePosition="left" state="on" inset="2" id="g7x-9J-1xC">
+                                                            <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
+                                                            <font key="font" metaFont="system"/>
+                                                        </buttonCell>
+                                                    </button>
                                                 </subviews>
                                             </view>
                                         </box>
@@ -2387,6 +2395,7 @@
                 <outlet property="FastBootPatch" destination="4718" id="4734"/>
                 <outlet property="HDWriteProtection" destination="4668" id="4681"/>
                 <outlet property="MMU_Emulation" destination="39w-d7-zDS" id="Pzs-It-jZi"/>
+                <outlet property="SDL2Resizable" destination="6Qc-ZR-WJc" id="825-XQ-INr"/>
                 <outlet property="SDL2UseLinearScaling" destination="Sco-Iv-wnc" id="MwD-a7-vKU"/>
                 <outlet property="SDL2UseVSync" destination="Hti-Yj-SZa" id="hVb-NE-5eH"/>
                 <outlet property="TTRAMSizeStepper" destination="fv9-7a-2KO" id="lxM-bQ-6dz"/>

> Hi,
> Nicolas and Eero, thanks for your answer. 
> I'll disable sdl2 options buttons if sdl2 is not enabled for compiling. Just to be safe.
> Before send this diff I have to verify how runs this resizable button.
>  Miguel
> 
> 
>> Le 22/06/2017 à 21:08, Cocoa Pod a écrit :
>>> bonsoir,
>>>> For information, I'm adding a "Resizable" button in SDL2 options in xib (french & english) and associated code.
>>>> A+
>>>> Miguel
>>> This is done and runs. But I've questions before send diff file.
>>> -Is it possible to compile Hatari2 for SDL1.2x ?
>>> -if yes what I have to do with these three buttons for sdl2 options ?
>> 
>> Yes, it's possible to compile hatari with sdl1, but for OSX it seems the general opinion is that SDL1 is not performing correctly performance-wise under OSX.
>> 
>> So I think you can consider that OSX version will always be compiled using SDL2 and it should not be a problem if OSX version doesn't compile with SDL1.
>> 
>> Nicolas
>> 
>> 
> 
> Cocoa Pod
> http://cocoa.pod.free.fr/
> http://www.aconit.org/
> 
> 
> 
> 
> 

Cocoa Pod
http://cocoa.pod.free.fr/
http://www.aconit.org/





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/