Skip to content

Commit 29848ea

Browse files
committedJul 13, 2011
oh well - missed _the_ file...
1 parent 31cc5a7 commit 29848ea

File tree

1 file changed

+26
-2
lines changed

1 file changed

+26
-2
lines changed
 

‎src/plugins/globe/globe_plugin.cpp

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
Date : 08-Jul-2010
88
Copyright : (C) 2010 by Sourcepole
99
Email : info at sourcepole.ch
10-
/***************************************************************************
10+
***************************************************************************
1111
* *
1212
* This program is free software; you can redistribute it and/or modify *
1313
* it under the terms of the GNU General Public License as published by *
@@ -440,7 +440,11 @@ void GlobePlugin::setupControls()
440440
moveHControls->setFrame( new RoundedFrame() );
441441
moveHControls->getFrame()->setBackColor( 1, 1, 1, 0.5 );
442442
moveHControls->setMargin( 0 );
443-
moveHControls->setSpacing( 47 ); //OsgEarth >2.0: setChildSpacing( 47 );
443+
#if HAVE_OSGEARTH_CHILD_SPACING
444+
moveHControls->setChildSpacing( 47 );
445+
#else
446+
moveHControls->setSpacing( 47 );
447+
#endif
444448
moveHControls->setVertAlign( Control::ALIGN_CENTER );
445449
moveHControls->setHorizAlign( Control::ALIGN_CENTER );
446450
moveHControls->setPosition( 5, 30 );
@@ -462,7 +466,11 @@ void GlobePlugin::setupControls()
462466
moveVControls->setFrame( new RoundedFrame() );
463467
moveVControls->getFrame()->setBackColor( 1, 1, 1, 0.5 );
464468
moveVControls->setMargin( 0 );
469+
#if HAVE_OSGEARTH_CHILD_SPACING
470+
moveVControls->setChildSpacing( 36 );
471+
#else
465472
moveVControls->setSpacing( 36 );
473+
#endif
466474
moveVControls->setVertAlign( Control::ALIGN_CENTER );
467475
moveVControls->setHorizAlign( Control::ALIGN_CENTER );
468476
moveVControls->setPosition( 35, 5 );
@@ -492,7 +500,11 @@ void GlobePlugin::setupControls()
492500
rotateControls->setFrame( new RoundedFrame() );
493501
rotateControls->getFrame()->setBackColor( 1, 1, 1, 0.5 );
494502
rotateControls->setMargin( 0 );
503+
#if HAVE_OSGEARTH_CHILD_SPACING
504+
rotateControls->setChildSpacing( 10 );
505+
#else
495506
rotateControls->setSpacing( 10 );
507+
#endif
496508
rotateControls->setVertAlign( Control::ALIGN_CENTER );
497509
rotateControls->setHorizAlign( Control::ALIGN_CENTER );
498510
rotateControls->setPosition( 5, 113 );
@@ -526,7 +538,11 @@ void GlobePlugin::setupControls()
526538
tiltControls->setFrame( new RoundedFrame() );
527539
tiltControls->getFrame()->setBackColor( 1, 1, 1, 0.5 );
528540
tiltControls->setMargin( 0 );
541+
#if HAVE_OSGEARTH_CHILD_SPACING
542+
tiltControls->setChildSpacing( 30 );
543+
#else
529544
tiltControls->setSpacing( 30 );
545+
#endif
530546
tiltControls->setVertAlign( Control::ALIGN_CENTER );
531547
tiltControls->setHorizAlign( Control::ALIGN_CENTER );
532548
tiltControls->setPosition( 35, 90 );
@@ -554,7 +570,11 @@ void GlobePlugin::setupControls()
554570
zoomControls->setFrame( new RoundedFrame() );
555571
zoomControls->getFrame()->setBackColor( 1, 1, 1, 0.5 );
556572
zoomControls->setMargin( 0 );
573+
#if HAVE_OSGEARTH_CHILD_SPACING
574+
zoomControls->setChildSpacing( 5 );
575+
#else
557576
zoomControls->setSpacing( 5 );
577+
#endif
558578
zoomControls->setVertAlign( Control::ALIGN_CENTER );
559579
zoomControls->setHorizAlign( Control::ALIGN_CENTER );
560580
zoomControls->setPosition( 35, 170 );
@@ -582,7 +602,11 @@ void GlobePlugin::setupControls()
582602
extraControls->setFrame( new RoundedFrame() );
583603
extraControls->getFrame()->setBackColor( 1, 1, 1, 0.5 );
584604
extraControls->setMargin( 0 );
605+
#if HAVE_OSGEARTH_CHILD_SPACING
606+
extraControls->setChildSpacing( 10 );
607+
#else
585608
extraControls->setSpacing( 10 );
609+
#endif
586610
extraControls->setVertAlign( Control::ALIGN_CENTER );
587611
extraControls->setHorizAlign( Control::ALIGN_CENTER );
588612
extraControls->setPosition( 5, 220 );

0 commit comments

Comments
 (0)
Please sign in to comment.