@@ -717,6 +717,8 @@ protected override void OnPaint(PaintEventArgs e)
717717 }
718718 }
719719
720+
721+
720722 if ( ! drawButtonCount )
721723 {
722724 if ( S != 0 )
@@ -732,6 +734,25 @@ protected override void OnPaint(PaintEventArgs e)
732734 int drawRY = 68 - ( ( 64 * joyRY ) / 128 ) ;
733735
734736 e . Graphics . DrawImage ( imgBase , 108 - 64 , 68 - 64 , 128 , 128 ) ;
737+ if ( DPadBehave == 1 )
738+ {
739+ if ( DUp != 0 )
740+ {
741+ e . Graphics . DrawImage ( imgDUp , 92 , 3 , 32 , 62 ) ;
742+ }
743+ if ( DDown != 0 )
744+ {
745+ e . Graphics . DrawImage ( imgDDown , 92 , 71 , 32 , 62 ) ;
746+ }
747+ if ( DRight != 0 )
748+ {
749+ e . Graphics . DrawImage ( imgDRight , 111 , 52 , 62 , 32 ) ;
750+ }
751+ if ( DLeft != 0 )
752+ {
753+ e . Graphics . DrawImage ( imgDLeft , 43 , 52 , 62 , 32 ) ;
754+ }
755+ }
735756 if ( RStickBehave == 1 && ( joyRX != 0 || joyRY != 0 ) )
736757 {
737758 e . Graphics . DrawLine ( penRStick , 108 , 68 , drawRX , drawRY ) ;
@@ -793,27 +814,6 @@ protected override void OnPaint(PaintEventArgs e)
793814 e . Graphics . DrawString ( "" + countS , fontArial , Brushes . White , recS , formatLeft ) ;
794815 e . Graphics . DrawString ( "" + countS2 , fontArial , Brushes . White , recS2 , formatRight ) ;
795816 }
796-
797- if ( DPadBehave == 1 && drawButtonCount == false )
798- {
799- if ( DUp != 0 )
800- {
801- e . Graphics . DrawImage ( imgDUp , 92 , 3 , 32 , 62 ) ;
802- }
803- if ( DDown != 0 )
804- {
805- e . Graphics . DrawImage ( imgDDown , 92 , 71 , 32 , 62 ) ;
806- }
807- if ( DRight != 0 )
808- {
809- e . Graphics . DrawImage ( imgDRight , 111 , 52 , 62 , 32 ) ;
810- }
811- if ( DLeft != 0 )
812- {
813- e . Graphics . DrawImage ( imgDLeft , 43 , 52 , 62 , 32 ) ;
814- }
815- }
816-
817817 base . OnPaint ( e ) ;
818818 }
819819
0 commit comments