DESCRIPTION

Bug 478611 - [DataBinding] Create snippets for the SideEffect class

Change-Id: Ifb0c53b6779e99d6b945b5647a2c157a4dcb6a4b
Signed-off-by: Krista Shepherd xxx@xxx.xxx

COMMENTS

author: Krista Shepherd
date: 2016-03-09 19:34:17.000000000

Uploaded patch set 1.

-------------------------------------
author: Brenden Conley
date: 2016-03-09 20:49:06.000000000

Patch Set 1:

Build Started https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/8577/

-------------------------------------
author: Brenden Conley
date: 2016-03-09 21:15:16.000000000

Patch Set 1: Verified+1

Build Successful 

https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/8577/ : SUCCESS

-------------------------------------
author: Kelly Potter
date: 2016-03-10 05:38:29.000000000

Patch Set 1: Code-Review-1

(3 comments)

Minor layout suggestions... and recommend against discouraging DBC until the SideEffect version can be made more concise.

Line:51, examples/org.eclipse.jface.examples.databinding/src/org/eclipse/jface/examples/databinding/snippets/SnippetSideEffectMigration.java -> I like the ISideEffect approach since it's more general, but the DBC approach is still fewer lines of code and I don't think we should discourage the usage of DBC until such time as the ISideEffect version can be implemented as concisely.

In particular, the need to dispose the side effects individually makes it somewhat cumbersome. I'll post some ideas on how to fix this on the bug report.

Line:139, examples/org.eclipse.jface.examples.databinding/src/org/eclipse/jface/examples/databinding/snippets/SnippetSideEffectMigration.java -> Suggest the use of GridLayoutFactory.generate(...) at the end of the method rather than GridLayoutFactory.applyTo at the start of the method. That would let you delete all the calls to GridDataFactory, below.
Also: use GridLayoutFactory.fillDefaults() rather than swtDefaults().

Line:251, examples/org.eclipse.jface.examples.databinding/src/org/eclipse/jface/examples/databinding/snippets/SnippetSideEffectMigration.java -> Suggest the use of GridLayoutFactory.generate(...) at the end of the method rather than GridLayoutFactory.applyTo at the start of the method. That would let you delete all the calls to GridDataFactory, below.

Also: use GridLayoutFactory.fillDefaults() rather than swtDefaults().

-------------------------------------
author: Krista Shepherd
date: 2016-03-12 23:45:50.000000000

Abandoned

Abandoned due to a newer version of this sample https://git.eclipse.org/r/#/c/68283/1

-------------------------------------
