Disable DOM element focusing in some widgets

Most of the browsers auto-scroll DOM element into view, when it's
focused. This leads to unwanted app scroll, when website-like scrolling
is eanbled.

Set widget enableElementFocus property to false for Grid, List,
Composite, Group, ScrolledComposite, TabFolder and CTabfolder.

Change-Id: I4fdc64e429081b5dc6673143223cef3449afc2b5
diff --git a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/CTabFolder.js b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/CTabFolder.js
index 95df2e0..6efb9c8 100644
--- a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/CTabFolder.js
+++ b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/CTabFolder.js
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2002, 2015 Innoopract Informationssysteme GmbH.
+ * Copyright (c) 2002, 2016 Innoopract Informationssysteme GmbH.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -20,6 +20,7 @@
     this.setHideFocus( true );
     this.setAppearance( "ctabfolder" );
     this.setOverflow( "hidden" );
+    this.setEnableElementFocus( false );
     this._tabPosition = "top";
     this._tabHeight = 0;
     this._selectionForeground = null;
diff --git a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Composite.js b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Composite.js
index 24b1257..366105d 100644
--- a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Composite.js
+++ b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Composite.js
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2009, 2015 EclipseSource and others.
+ * Copyright (c) 2009, 2016 EclipseSource and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -20,6 +20,7 @@
     this.setAppearance( "composite" );
     this.setOverflow( "hidden" );
     this.setHideFocus( true );
+    this.setEnableElementFocus( false );
     // Disable scrolling (see bug 345903)
     rwt.widgets.base.Widget.disableScrolling( this );
     this._clientArea = [ 0, 0, 0, 0 ];
diff --git a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Grid.js b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Grid.js
index 6a0d0f7..435fbc1 100644
--- a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Grid.js
+++ b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Grid.js
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2010, 2015 Innoopract Informationssysteme GmbH and others.
+ * Copyright (c) 2010, 2016 Innoopract Informationssysteme GmbH and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -47,6 +47,7 @@
     this._config = this._rowContainer.getRenderConfig();
     this.setCursor( "default" );
     this.setOverflow( "hidden" );
+    this.setEnableElementFocus( false );
     rwt.widgets.base.Widget.disableScrolling( this ); // see bugs 279460 and 364739
     rwt.widgets.util.ScrollBarsActivator.install( this );
     this._configureScrollBars();
diff --git a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Group.js b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Group.js
index 47b73e1..99108b0 100644
--- a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Group.js
+++ b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/Group.js
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2002, 2015 Innoopract Informationssysteme GmbH and others.
+ * Copyright (c) 2002, 2016 Innoopract Informationssysteme GmbH and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -23,6 +23,7 @@
     this._legend.setAppearance( "group-box-legend" );
     this.add( this._legend );
     this.setOverflow( "hidden" );
+    this.setEnableElementFocus( false );
     var themeValues = new rwt.theme.ThemeValues( {} );
     this._themeBackgroundColor = themeValues.getCssColor( "Group-Label", "background-color" );
     themeValues.dispose();
diff --git a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/List.js b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/List.js
index 66a7f00..b733575 100644
--- a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/List.js
+++ b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/List.js
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright: 2004, 2015 1&1 Internet AG, Germany, http://www.1und1.de,
+ * Copyright: 2004, 2016 1&1 Internet AG, Germany, http://www.1und1.de,
  *                       and EclipseSource
  *
  * This program and the accompanying materials are made available under the
@@ -19,6 +19,7 @@
     this.base( arguments, new rwt.widgets.base.VerticalBoxLayout() );
     this.setAppearance( "list" );
     this.setScrollBarsVisible( false, false );
+    this.setEnableElementFocus( false );
     this._manager = new rwt.widgets.util.SelectionManager( this._clientArea );
     this._manager.setMultiSelection( multiSelection );
     this._manager.setDragSelection( false );
diff --git a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/ScrolledComposite.js b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/ScrolledComposite.js
index 5769396..7d47789 100644
--- a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/ScrolledComposite.js
+++ b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/ScrolledComposite.js
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2002, 2014 Innoopract Informationssysteme GmbH and others.
+ * Copyright (c) 2002, 2016 Innoopract Informationssysteme GmbH and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -28,6 +28,7 @@
     this._focusRoot = null;
     this.addEventListener( "changeParent", this._onChangeParent, this );
     this.setAppearance( "scrolledcomposite" );
+    this.setEnableElementFocus( false );
   },
 
   members : {
diff --git a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/TabFolder.js b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/TabFolder.js
index d59a626..1394813 100644
--- a/bundles/org.eclipse.rap.rwt/js/rwt/widgets/TabFolder.js
+++ b/bundles/org.eclipse.rap.rwt/js/rwt/widgets/TabFolder.js
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2004, 2015 1&1 Internet AG, Germany, http://www.1und1.de,
+ * Copyright (c) 2004, 2016 1&1 Internet AG, Germany, http://www.1und1.de,
  *                          EclipseSource and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
@@ -25,6 +25,7 @@
     this._bar = new rwt.widgets.base.TabFolderBar();
     this._pane = new rwt.widgets.base.TabFolderPane();
     this.add( this._bar, this._pane );
+    this.setEnableElementFocus( false );
   },
 
   properties : {