[Title] modify button size setting
authorjihye kim <jihye1128.kim@samsung.com>
Mon, 9 Apr 2012 04:14:29 +0000 (13:14 +0900)
committerjihye kim <jihye1128.kim@samsung.com>
Mon, 9 Apr 2012 04:14:29 +0000 (13:14 +0900)
[Type] work
[Module] event injector
[Priority] major
[Jira#]
[Redmine#]
[Problem]
[Cause]
[Solution]
[TestCase]

org.tizen.sensor.accelerometer/src/org/tizen/sensor/accelerometer/page/Accelerometer.java

index 85dd17e..a247c1e 100644 (file)
@@ -44,6 +44,7 @@ import org.eclipse.swt.events.SelectionAdapter;
 import org.eclipse.swt.events.SelectionEvent;
 import org.eclipse.swt.events.SelectionListener;
 import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
 import org.eclipse.swt.widgets.Button;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Shell;
@@ -468,10 +469,16 @@ public class Accelerometer extends AbstractInjectorPage {
        }
        
        private void createRotationButton( Composite rotationComposite){
-               Button rotation0 = formUtil.createButton(rotationComposite, "Portrait", SWT.PUSH);
-           Button rotation90 = formUtil.createButton(rotationComposite, "Landscape", SWT.PUSH);
-           Button rotation180 = formUtil.createButton(rotationComposite, "Reverse Portrait", SWT.PUSH);
-           Button rotation270 = formUtil.createButton(rotationComposite, "Reverse Landscape", SWT.PUSH);
+               Composite buttonComposite = formUtil.createComposite(rotationComposite);
+               buttonComposite.setLayout(new GridLayout(4, true));
+               Button rotation0 = formUtil.createButton(buttonComposite, "Portrait", SWT.PUSH);
+               rotation0.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
+           Button rotation90 = formUtil.createButton(buttonComposite, "Landscape", SWT.PUSH);
+           rotation90.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
+           Button rotation180 = formUtil.createButton(buttonComposite, "Reverse Portrait", SWT.PUSH);
+           rotation180.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
+           Button rotation270 = formUtil.createButton(buttonComposite, "Reverse Landscape", SWT.PUSH);
+           rotation270.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, false));
            rotation0.addSelectionListener(new SelectionListener(){
                        @Override
                        public void widgetDefaultSelected(SelectionEvent e) {