Index: Dev/branches/rest-dojo-ui/client/rft/pages/survey.html
===================================================================
--- Dev/branches/rest-dojo-ui/client/rft/pages/survey.html	(revision 359)
+++ Dev/branches/rest-dojo-ui/client/rft/pages/survey.html	(revision 360)
@@ -1,3 +1,3 @@
-<div data-dojo-type="rft.pages.survey" id="survey" class="blue">
+<div data-dojo-type="rft.pages.survey" class="blue">
     <div data-dojo-type="dijit.layout.BorderContainer" data-dojo-props="region:'center'" style="height: 500px;">
 
@@ -10,5 +10,5 @@
         
         <div data-dojo-type="dijit.layout.BorderContainer" data-dojo-props="region:'center'">
-            <div id="tabList" data-dojo-type="dijit.layout.TabContainer" class="blue" data-dojo-props="tabPosition:'left-h',region:'center'">
+            <div data-rft-attach-point="tabList" data-dojo-type="dijit.layout.TabContainer" class="blue" data-dojo-props="tabPosition:'left-h',region:'center'">
                 <!-- tabs go here -->
             </div>
@@ -16,12 +16,12 @@
         
         <div data-dojo-type="dijit.layout.BorderContainer" data-dojo-props="region:'right'" style="width: 300px">
-            <div id="SurveyListViewNode" class="rftSurveyListView">
+            <div data-rft-attach-point="surveyListViewNode" class="rftSurveyListView">
             </div>
 
             <div data-dojo-type="dijit.layout.ContentPane" data-dojo-props="region: 'bottom'">
-                <button id="btnProperties" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconProperties'">Properties</button>
-                <button id="btnSave" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconAccept'">Save Changes</button>
-                <button id="btnDiscard" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconCancel'">Discard changes</button>
-                <button id="btnPreview" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconPreview'">Preview</button>
+                <button data-rft-attach-point="btnProperties" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconProperties'">Properties</button>
+                <button data-rft-attach-point="btnSave" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconAccept'">Save Changes</button>
+                <button data-rft-attach-point="btnDiscard" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconCancel'">Discard changes</button>
+                <button data-rft-attach-point="btnPreview" data-dojo-type="dijit.form.Button" data-dojo-props="baseClass: 'rftLargeButton', iconClass: 'rftIcon rftIconPreview'">Preview</button>
             </div>
         </div>
Index: Dev/branches/rest-dojo-ui/client/rft/pages/survey.js
===================================================================
--- Dev/branches/rest-dojo-ui/client/rft/pages/survey.js	(revision 359)
+++ Dev/branches/rest-dojo-ui/client/rft/pages/survey.js	(revision 360)
@@ -1,169 +1,93 @@
 define(['dojo/_base/declare',
-	'dojo/_base/lang',
-	'dojo/_base/event',
-	'dojo/_base/Deferred',
-	'rft/ui/AccordionList',
-	'rft/ui/LineWithActionsWidget',
-	'rft/ui/SurveyListView',
-	'rft/store',
-	'rft/ui/_Page',
-	'rft/api',
-	'dijit/registry',
-	'rft/content',
-	'dojo/on',
-	'dojo/query'],
-	function(declare,lang,event,Deferred,AccordionList,LineWithActionsWidget,SurveyListView,store,_Page,api,registry,content, on, query){
-		return declare('rft.pages.survey',[_Page],{
-			object: null,
-			questions: null,
-			listView: null,
-			
-			onVisit: function() {
-				if ( this.pageArgs.uid ) {	// Load survey
-					Deferred.when(store.get(this.pageArgs.uid))
-					.then(lang.hitch(this,function(obj){
-						this.object = obj;
-						return Deferred.when( obj.creator && store.dereference(obj.creator) );
-					}));
-
-					//this._createQuestionBrowser();	// Load questions database and create browser
-					this.questions = new dojo.store.Memory({	// Create local copy store of questions database
-						data: [],
-						idProperty: "_id"
-					});
-				} else {
-					throw "No valid uid or survey passed!";
-				}
-				this._setupButtons(this);
-				var testQuestion1 = {_id: "123", title: "How long have you worked here?", categories: ['Professional background'], topic: 'Work experience'};
-				this.questions.add(testQuestion1);
-				this._insertQuestion(testQuestion1);
-				var testQuestion2 = {_id: "234", title: "How many years have you been employed here?", categories: ['Respondent personals','Professional background'], topic: 'Work experience'};
-				this.questions.add(testQuestion2);
-				this._insertQuestion(testQuestion2);
-				var testQuestion3 = {_id: "345", title: "Have you worked here longer than 10 years?", categories: ['Respondent personals','Professional background'], topic: 'Work experience'};
-				this.questions.add(testQuestion3);
-				this._insertQuestion(testQuestion3);
-				var testQuestion4 = {_id: "456", title: "Rate your experience at your current employer from 1 to 10.", categories: ['Respondent personals','Professional background'], topic: 'Work experience'};
-				this.questions.add(testQuestion4);
-				this._insertQuestion(testQuestion4);
-				
-				this._createListView(this.questions);
-			},
-			onLeave: function() {
-				this.inherited(arguments);
-			},
-			onReset: function() {
-				this.setFields(this.object);
-			},
-			onSave: function(evt) {
-				/*lang.mixin(this.object,this.form.get('value'));
-				Deferred.when( store.put(this.object) )
-				.then(lang.hitch(this,function(obj){
-				this.object = obj;
-				this.setFields(obj);
-				api.notify("Object saved");
-				}),lang.hitch(this,function(){
-				api.notify("Object save failed",'error');
-				}));
-				event.stop(evt);
-				evt.stopPropagation();
-				return false;
-				*/
-			},
-			_goToPreview: function() {
-				content.goTo('surveyAdvanced', {uid: this.object._id});
-			},
-			_setupButtons: function() {
-				// Setup button events
-				registry.byId("btnSave").on("click", lang.hitch(this, function(){
-					this.onSave(arguments);
-				}));
-				registry.byId("btnPreview").on("click", lang.hitch(this, function(){
-					this._goToPreview();
-				}));
-			},
-			/* Store code */
-			getQuestion: function(_id) {
-				return this.questions.get(_id);
-			},
-			setQuestion: function(question) {
-				return this.questions.put(question);
-			},
-			/* Browser code */
-			_createQuestionBrowser: function() { // TODO: Do all operations from the local store. Put querying routine in SyncStore()!
-				var getQuestions = function(self){
-					return questions = Deferred.when(store.query('_design/default/_view/by_type', {key:'Question'}), function(res){
-						self.questions.setData(res);	// Store queried questions in this.questions MemoryStore
-						return res;
-					});
-				};
-
-				Deferred.when(getQuestions(this), lang.hitch(this, function(questions){
-					questions.forEach(function(question){
-						this._insertQuestion(question)
-					}, this);
-				}), function(err){
-					throw "Questions could not be fetched. No connection or null query!";
-				});
-			},
-			_insertQuestion: function(question) {
-				var tabs = registry.byId("tabList");
-				for (var c in question.categories) {
-					var cat = question.categories[c];
-					var q = "div[data-category='"+cat+"']";
-					var catPane = query(q, tabs.containerNode)[0];
-					if (catPane) {
-						this._insertIntoCategory(question, catPane);
-					} else {
-						catPane = this._createCategoryTab(cat);
-						if (catPane) {
-							this._insertIntoCategory(question, catPane);
-						} else {
-							throw "Error: could not find or create category pane!";
-						}
-					}
-				}
-			},
-			_createCategoryTab: function(category) {
-				var tabs = registry.byId("tabList");
-				var newCat = new dijit.layout.ContentPane({
-					title: category,
-					postCreate: function(){
-						this.domNode.dataset["category"] = category;
-					}
-				});
-				newCat.domNode.id = "tab"+category;
-				tabs.addChild(newCat);
-				var q = "div[data-category='"+category+"']";
-				var pane = query(q, tabs.containerNode)[0];
-				return (pane) ? pane : false;
-			},
-			_insertIntoCategory: function(question, container) {
-				var selector = query(".rftSelector[data-topic='"+question.topic+"']", container)[0];
-				var selectorWidget;
-				if (selector) {
-					selectorWidget = registry.byNode(selector);
-
-				} else {
-					selectorWidget = new rft.ui.Selector({
-						topic: question.topic,
-						controller: this
-					});
-					selectorWidget.placeAt(container);
-				}
-				selectorWidget.addQuestion(question._id);
-			},
-			/* ListView code */
-			_createListView: function() {
-				this.listView = new SurveyListView({
-					controller: this
-				}).placeAt("SurveyListViewNode");
-			},
-			IncludeQuestion: function(_id) {
-				this.listView.insertItem(_id);
-			},
-
-		});
+    'dojo/_base/lang',
+    'dojo/_base/event',
+    'dojo/_base/Deferred',
+    'rft/ui/Selector',
+    'rft/ui/SurveyListView',
+    'dijit/layout/ContentPane',
+    'rft/store',
+    'rft/ui/_Page',
+    'rft/content',
+    'dojo/store/Cache',
+    'dojo/store/Memory' ],
+    function(declare,lang,event,Deferred,Selector,SurveyListView,ContentPane,store,_Page,content,Cache,Memory){
+        return declare('rft.pages.survey',[_Page],{
+            object: null,
+            listView: null,
+            _dataMap: null,
+            constructor: function(){
+                this._dataMap = {};
+            },
+            onVisit: function() {
+                if ( this.pageArgs.uid ) {
+                    Deferred.when(store.get(this.pageArgs.uid))
+                    .then(lang.hitch(this,function(obj){
+                        this.object = obj;
+                        return Deferred.when( obj.creator && store.dereference(obj.creator) );
+                    }));
+                    this._createListView();
+                    this._createQuestionBrowser();
+                    this._setupButtons();
+                } else {
+                    throw "No valid uid or survey passed!";
+                }
+            },
+            _goToPreview: function() {
+                content.goTo('surveyAdvanced', {uid: this.object._id});
+            },
+            _setupButtons: function() {
+                this.btnSave.on("click", lang.hitch(this, this.onSave));
+                this.btnPreview.on("click", lang.hitch(this, this._goToPreview));
+            },
+            _createQuestionBrowser: function() {
+                store.query('_design/default/_view/by_type', {key:'Question'})
+                .forEach(function(question){
+                    this._insertQuestion(question);
+                },this);
+            },
+            _insertQuestion: function(question) {
+                for (var c in question.categories) {
+                    var cat = question.categories[c];
+                    if (this._dataMap[cat] === undefined) {
+                        this._dataMap[cat] = {
+                            widget: this._createCategoryTab(cat),
+                            topics: {}
+                        }
+                    }
+                    this._insertIntoCategory(question,this._dataMap[cat]);
+                }
+            },
+            _createCategoryTab: function(category) {
+                var categoryTab = new ContentPane({
+                    title: category
+                });
+                categoryTab.startup();
+                this.tabList.addChild(categoryTab);
+                return categoryTab;
+            },
+            _insertIntoCategory: function(question, categoryMap) {
+                if (categoryMap[question.topic] === undefined) {
+                    var w = new Selector({
+                        title: question.topic
+                    }).placeAt(categoryMap.widget.containerNode);
+                    w.startup();
+                    w.on('include',lang.hitch(this,this.includeQuestion));
+                    categoryMap[question.topic] = {
+                        widget: w
+                    };
+                }
+                categoryMap[question.topic].widget.addItem(question);
+            },
+            /* ListView code */
+            _createListView: function() {
+                this.listView = new SurveyListView({
+                    controller: this
+                }).placeAt(this.surveyListViewNode);
+                this.listView.startup();
+            },
+            includeQuestion: function(question) {
+                this.listView.insertItem(question);
+            }
+        });
 });
 
Index: Dev/branches/rest-dojo-ui/client/rft/ui/Selector.js
===================================================================
--- Dev/branches/rest-dojo-ui/client/rft/ui/Selector.js	(revision 359)
+++ Dev/branches/rest-dojo-ui/client/rft/ui/Selector.js	(revision 360)
@@ -4,4 +4,5 @@
     'dijit/registry',
     'dojo/_base/lang',
+    'dojo/_base/event',
     'dojo/fx',
     'dijit/_WidgetBase',
@@ -17,4 +18,5 @@
         registry,
         lang,
+        event,
         fx,
         _WidgetBase,
@@ -28,21 +30,22 @@
         return declare('rft.ui.Selector',[_WidgetBase,_TemplatedMixin,_WidgetsInTemplateMixin,_Container],{
             templateString: templateString,
-            title: "ERROR: NULL_TOPIC",
+            title: "",
             baseClass: 'rftSelector',
             modifiers: 'blue',
-            currentlySelectedId: null,
-            controller: null,   // Use events/pubsub instead of a controller variable? Decoupling!
+            _folded: true,
+            _titleLine: null,
+            _selectorLine: null,
+            _selectedItem: null,
 
-            postCreate: function() {
+            startup: function() {
                 domClass.add(this.domNode, this.modifiers);
                 domClass.add(this.selectedColorNode, "pending");
-                this.domNode.dataset["topic"] = this.topic;
 
-                new LineWithActionsWidget({
-                    title: this.topic,
+                this._titleLine = new LineWithActionsWidget({
+                    title: this.title,
                     modifiers: this.modifiers,
                     actions: {
-                        "AddToSurvey" : {
-                            callback: lang.hitch(this, this.includeQuestion),
+                        "Include in survey" : {
+                            callback: lang.hitch(this, this._onInclude),
                             properties: {
                                 blockButton: true,
@@ -54,11 +57,12 @@
                     }
                 },this.titleNode);
+                this._titleLine.startup();
 
-                this.selectorLine = new LineWithActionsWidget({
+                this._selectorLine = new LineWithActionsWidget({
                     title: 'None',
                     modifiers: this.modifiers,
                     actions: {
-                        "ToggleDropdown" : {
-                            callback: lang.hitch(this, this._toggleDropdown()),
+                        "Toggle dropdown" : {
+                            callback: lang.hitch(this, this._onToggleDropdown),
                             properties: {
                                 blockButton: true,
@@ -70,93 +74,75 @@
                     }
                 },this.selectedItemNode);
+                this._selectorLine.startup();
+
+                fx.wipeOut({
+                    node: this.optionsNode
+                }).play();
             },
-            _toggleDropdown: function() {
-                var node = this.optionsNode;
-                var show = fx.wipeIn({
-                    node: node
-                });
-                var hide = fx.wipeOut({
-                    node: node
-                });
-                hide.play();
-                var folded = true;
-                return function(e) {
-                    if ( folded ) {
-                        var downArrowIcon = dojo.query(".rftBlockButton .rftIconHalfArrowDown", this.selectorLine.buttonsNode)[0];
-                        if (downArrowIcon){
-                            domClass.replace(downArrowIcon, "rftIconHalfArrowUp", "rftIconHalfArrowDown");
+            _onSelect: function(item, widget) {
+                this._selectedItem = item;
+                this._onToggleDropdown();
+                this._selectorLine.set("title", item.title);
+                baseArray.forEach(this.optionsNode.childNodes, function(node){
+                    var line = registry.byNode(node);
+                    if (line) {
+                        if (line === widget) {
+                            domClass.add(line.domNode, "inheritBgColor light");
+                        } else {
+                            domClass.remove(line.domNode, "inheritBgColor light");
                         }
-                        show.play();
-                        folded = false;
-                    } else {
-                        var upArrowIcon = dojo.query(".rftBlockButton .rftIconHalfArrowUp", this.selectorLine.buttonsNode)[0];
-                        if (upArrowIcon){
-                            domClass.replace(upArrowIcon, "rftIconHalfArrowDown", "rftIconHalfArrowUp");
-                        }
-                        hide.play();
-                        folded = true;
-
                     }
-                    e.preventDefault();
-                    e.stopPropagation();
-                };
+                }, this);
+                this.onSelect(item);
             },
-            addQuestion: function(questionId) {
-                var question = this.controller.getQuestion(questionId);
-                if (question) {
-                    var w = new LineWithActionsWidget({
-                        title: question.title,
-                        questionId: questionId,
-                        actions: {
-                            "InfoHover" : {
-                                callback: dojo.partial(this.infoFunction, this),
-                                properties: {
-                                    blockButton: false,
-                                    showLabel: false,
-                                    icon: "Inspect"
-                                }
+            _onInclude: function() {
+                if (this._selectedItem) {
+                    this.onInclude(this._selectedItem);
+                }
+            },
+            _onToggleDropdown: function(evt) {
+                if (this._folded) {
+                    var downArrowIcon = dojo.query(".rftBlockButton .rftIconHalfArrowDown", this._selectorLine.buttonsNode)[0];
+                    if (downArrowIcon){
+                        domClass.replace(downArrowIcon, "rftIconHalfArrowUp", "rftIconHalfArrowDown");
+                    }
+                    fx.wipeIn({
+                        node: this.optionsNode
+                    }).play();
+                    this._folded = false;
+                } else {
+                    var upArrowIcon = dojo.query(".rftBlockButton .rftIconHalfArrowUp", this._selectorLine.buttonsNode)[0];
+                    if (upArrowIcon){
+                        domClass.replace(upArrowIcon, "rftIconHalfArrowDown", "rftIconHalfArrowUp");
+                    }
+                    fx.wipeOut({
+                        node: this.optionsNode
+                    }).play();
+                    this._folded = true;
+                }
+                evt && event.stop(evt);
+                return false;
+            },
+            addItem: function(item) {
+                var w = new LineWithActionsWidget({
+                    title: item.title,
+                    actions: {
+                        "Info" : {
+                            callback: function() {
+                                item.description && alert(item.description);
+                            },
+                            properties: {
+                                blockButton: false,
+                                showLabel: false,
+                                icon: "Inspect"
                             }
                         }
-                    });
-                    w.placeAt(this.optionsNode);
-                    w.on("click", lang.hitch(this, function(){
-                        this.selectQuestion(questionId);
-                        this._toggleDropdown();
-                    }, questionId));
-
-                }    
+                    }
+                }).placeAt(this.optionsNode);
+                w.startup();
+                w.on("click", lang.hitch(this, this._onSelect, item, w));
             },
-            infoFunction: function(selector) {
-                var question = selector.controller.getQuestion(this.questionId);
-                console.log(question);
-                alert("Some info here!");
-            },
-            includeQuestion: function() {
-                if (this.currentlySelectedId) {
-                    this.controller.IncludeQuestion(this.currentlySelectedId)
-                } else {
-                    return false;
-                }
-            },
-            selectQuestion: function(questionId) {
-                /* TODO: TEST THOROUGHLY! */
-                var question = this.controller.getQuestion(questionId);
-                if (question) {
-                    this.currentlySelectedId = questionId;
-                    this.selectorLine.questionId = questionId;
-                    this.selectorLine.set("title", question.title);
-                    // Iterate through optionsNode, add "selected" class to currently selected node
-                    baseArray.forEach(this.optionsNode.childNodes, function(node, index){
-                        var line = registry.byNode(node);
-                        if (line) {
-                            if (line.questionId == this.currentlySelectedId) {
-                                domClass.add(line.domNode, "inheritBgColor light");
-                            } else {
-                                domClass.remove(line.domNode, "inheritBgColor light");
-                            }
-                        }
-                    }, this);
-                }
-            }
+            onSelect: function(item) {},
+            onInclude: function(item) {}
         });
 });
Index: Dev/branches/rest-dojo-ui/client/rft/ui/SurveyListView.js
===================================================================
--- Dev/branches/rest-dojo-ui/client/rft/ui/SurveyListView.js	(revision 359)
+++ Dev/branches/rest-dojo-ui/client/rft/ui/SurveyListView.js	(revision 360)
@@ -1,156 +1,151 @@
 define([
-	'dojo/_base/declare',
-	'dijit/_WidgetBase',
-	'dijit/_TemplatedMixin',
-	'dojo/_base/lang',
-	'dojo/fx',
-	'dojo/_base/fx',
-	'dijit/_WidgetsInTemplateMixin',
-	'dijit/_Container',
-	'rft/ui/LineWithActionsWidget',
-	'dojo/text!./templates/SurveyListView.html'
-	],function(
-		declare,
-		_WidgetBase,
-		_TemplatedMixin,
-		lang,
-		fx,
-		baseFx,
-		_WidgetsInTemplateMixin,
-		_Container,
-		LineWithActionsWidget,
-		templateString
-		){
-		return declare('rft.ui.SurveyListView',[_WidgetBase,_TemplatedMixin,_WidgetsInTemplateMixin,_Container],{
-			templateString: templateString,
-			baseClass: 'rftSurveyListView',
-			source: null,
-			controller: null,
-			region: 'center',
+    'dojo/_base/declare',
+    'dijit/_WidgetBase',
+    'dijit/_TemplatedMixin',
+    'dojo/_base/lang',
+    'dojo/fx',
+    'dojo/_base/fx',
+    'dijit/_WidgetsInTemplateMixin',
+    'dijit/_Container',
+    'rft/ui/LineWithActionsWidget',
+    'dojo/text!./templates/SurveyListView.html'
+    ],function(
+        declare,
+        _WidgetBase,
+        _TemplatedMixin,
+        lang,
+        fx,
+        baseFx,
+        _WidgetsInTemplateMixin,
+        _Container,
+        LineWithActionsWidget,
+        templateString
+        ){
+        return declare('rft.ui.SurveyListView',[_WidgetBase,_TemplatedMixin,_WidgetsInTemplateMixin,_Container],{
+            templateString: templateString,
+            baseClass: 'rftSurveyListView',
+            source: null,
+            region: 'center',
 
-			postCreate: function() {
-				if (this.title) {
-					this.titleNode.innerHTML = this.title;
-				} else {
-					this.domNode.removeChild(this.titleNode);
-				}
+            postCreate: function() {
+                if (this.title) {
+                    this.titleNode.innerHTML = this.title;
+                } else {
+                    this.domNode.removeChild(this.titleNode);
+                }
 
-				this.source = new dojo.dnd.Source(this.sourceNode, {
-					isSource: true,
-					accept: ["SurveyListViewItem"],
-					horizontal: false,
-					withHandles: false,
-					copyOnly: false,
-					selfCopy: false,
-					selfAccept: true,
-					delay: 0,
-					singular: true,
-					creator: dojo.partial(this.creatorMethod, this.controller, this)
-				});
+                this.source = new dojo.dnd.Source(this.sourceNode, {
+                    isSource: true,
+                    accept: ["SurveyListViewItem"],
+                    horizontal: false,
+                    withHandles: false,
+                    copyOnly: false,
+                    selfCopy: false,
+                    selfAccept: true,
+                    delay: 0,
+                    singular: true,
+                    creator: lang.hitch(this, this.creatorMethod)
+                });
 
-				new dijit.form.Button({
-					label: "Move up",
-					showLabel: false,
-					iconClass: "rftIcon rftIconFullArrowUp",
-					baseClass: "rftBlockButton",
-					class: "trans",
-					onClick: lang.hitch(this, function() {
-						this.moveItem("up");
-					})
-				}, this.btnListMoveUp);
+                new dijit.form.Button({
+                    label: "Move up",
+                    showLabel: false,
+                    iconClass: "rftIcon rftIconFullArrowUp",
+                    baseClass: "rftBlockButton",
+                    'class': "trans",
+                    onClick: lang.hitch(this, function() {
+                        this.moveItem("up");
+                    })
+                }, this.btnListMoveUp);
 
-				new dijit.form.Button({
-					label: "Move down",
-					showLabel: false,
-					iconClass: "rftIcon rftIconFullArrowDown",
-					baseClass: "rftBlockButton",
-					class: "trans",
-					onClick: lang.hitch(this, function() {
-						this.moveItem("down");
-					})
-				}, this.btnListMoveDown);
-			},
-			creatorMethod: function(controller, listView, item, hint) {
-				var node,
-				object = controller.getQuestion(item);
-				if (!object) {
-					return false;
-				}
+                new dijit.form.Button({
+                    label: "Move down",
+                    showLabel: false,
+                    iconClass: "rftIcon rftIconFullArrowDown",
+                    baseClass: "rftBlockButton",
+                    'class': "trans",
+                    onClick: lang.hitch(this, function() {
+                        this.moveItem("down");
+                    })
+                }, this.btnListMoveDown);
+            },
+            creatorMethod: function(item, hint) {
+                var node;
 
-				if (hint == "avatar") {
-					node = document.createElement("div");
-					node.className = "dragAvatar";
-					node.innerHTML = object.title;
-				} else {
-					var w = new LineWithActionsWidget({
-						title: object.title,
-						class: "inheritBgColor",
-						actions: {
-							"Remove" : {
-								callback: lang.hitch(listView, function(evt){
-									this.removeItem(evt);
-								}),
-								properties: {
-									blockButton: false,
-									icon: "Delete",
-									modifiers: "white",
-									label: "Remove"
-								}
-							},
-							"Info" : {
-								callback: function(){
-									var question = controller.getQuestion(item);
-									console.log(question);
-									alert("info goes here yo!");
-								},
-								properties: {
-									blockButton: false,
-									icon: "Inspect",
-									modifiers: "white",
-									label: "Show info"
-								}
-							}
-						}
-					});
-					w.startup();
-					node = w.domNode;
-				}
-				var fullItem = {node: node, data: item, type: "SurveyListviewItem"}
-				return fullItem;
-			},
-			moveItem: function(dir) {
-				var node = this.source.getSelectedNodes()[0];
-				if (node) {
-					if (dir == "up") {
-						if (node.previousSibling) {
-							return node.parentNode.insertBefore(node, node.previousSibling);
-						} else {
-							return false;
-						}
+                if (hint == "avatar") {
+                    node = document.createElement("div");
+                    node.className = "dragAvatar";
+                    node.innerHTML = item.title;
+                } else {
+                    var w = new LineWithActionsWidget({
+                        title: item.title,
+                        'class': "inheritBgColor",
+                        actions: {
+                            "Remove" : {
+                                callback: lang.hitch(this, function(){
+                                    this.removeItem(item, w);
+                                }),
+                                properties: {
+                                    blockButton: false,
+                                    icon: "Delete",
+                                    modifiers: "white",
+                                    label: "Remove"
+                                }
+                            },
+                            "Info" : {
+                                callback: function(){ item.description && alert(item.description); },
+                                properties: {
+                                    blockButton: false,
+                                    icon: "Inspect",
+                                    modifiers: "white",
+                                    label: "Show info"
+                                }
+                            }
+                        }
+                    });
+                    w.startup();
+                    node = w.domNode;
+                }
+                var fullItem = {
+                    node: node,
+                    data: item,
+                    type: "SurveyListviewItem"
+                };
+                return fullItem;
+            },
+            moveItem: function(dir) {
+                var node = this.source.getSelectedNodes()[0];
+                if (node) {
+                    if (dir == "up") {
+                        if (node.previousSibling) {
+                            return node.parentNode.insertBefore(node, node.previousSibling);
+                        } else {
+                            return false;
+                        }
 
-					} else if (dir == "down") {
-						if (node.nextSibling) {
-							return node.parentNode.insertBefore(node.nextSibling, node);
-						} else {
-							return false;
-						}
-					} else {
-						throw "Invalid move direction passed!";
-					}
-				} else {
-					return false;
-				}
-			},
-			insertItem: function(objectId) {
-				var anchor = this.source.getSelectedNodes()[0];
-				if (anchor) {
-					this.source.insertNodes(false, [objectId], false, anchor);
-				} else {
-					this.source.insertNodes(false, [objectId]);
-				}
-			},
-			removeItem: function(evt){
-				debugger;
-			}
-		});
+                    } else if (dir == "down") {
+                        if (node.nextSibling) {
+                            return node.parentNode.insertBefore(node.nextSibling, node);
+                        } else {
+                            return false;
+                        }
+                    } else {
+                        throw "Invalid move direction passed!";
+                    }
+                } else {
+                    return false;
+                }
+            },
+            insertItem: function(item) {
+                var anchor = this.source.getSelectedNodes()[0];
+                if (anchor) {
+                    this.source.insertNodes(false,[item], false, anchor);
+                } else {
+                    this.source.insertNodes(false,[item]);
+                }
+            },
+            removeItem: function(item,widget){
+                widget.destroy();
+            }
+        });
 });
