[gnome-documents] view: update for new GdMainView selection API
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-documents] view: update for new GdMainView selection API
- Date: Mon, 5 Mar 2012 22:21:36 +0000 (UTC)
commit 0ef814df0089ed4b94c7e546db8cbc4bac6d9a1f
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Mon Feb 27 19:35:07 2012 -0500
view: update for new GdMainView selection API
src/view.js | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/src/view.js b/src/view.js
index 3bc39ba..318b5a4 100644
--- a/src/view.js
+++ b/src/view.js
@@ -234,7 +234,7 @@ View.prototype = {
let urnIndex = selected.indexOf(urn);
if (urnIndex != -1) {
- generic.select_path(path);
+ this._treeModel.set_value(iter, Gd.MainColumns.SELECTED, true);
selected.splice(urnIndex, 1);
if (first) {
@@ -256,10 +256,8 @@ View.prototype = {
},
_onSelectionChanged: function() {
- let generic = this.widget.get_generic_view();
-
// update the selection on the controller when the view signals a change
- let selectedURNs = Utils.getURNsFromPaths(generic.get_selection(),
+ let selectedURNs = Utils.getURNsFromPaths(this.widget.get_selection(),
this._treeModel);
Global.selectionController.setSelection(selectedURNs);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]