[polari/wip/fmuellner/combined-gsoc: 11/103] experimental: substring index
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [polari/wip/fmuellner/combined-gsoc: 11/103] experimental: substring index
- Date: Fri, 22 Jul 2016 13:34:53 +0000 (UTC)
commit 105cc69a50245f7f4dfc1d2991a8ff70ce3a3490
Author: Kunaal Jain <kunaalus gmail com>
Date: Sun Jun 12 22:44:46 2016 +0530
experimental: substring index
src/mainWindow.js | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/mainWindow.js b/src/mainWindow.js
index 5f9ba0c..03ad86f 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -266,7 +266,7 @@ const MainWindow = new Lang.Class({
for (let i = 0; i < events.length; i++) {
let message = events[i].mms;
let uid = events[i].id;
- let index = 0;
+ let index = message.indexOf(this._keywords[0] - 5);
let row = this._widgetMap[uid];
for (let j = 0; j < this._keywords.length; j++) {
// log(this._keywords[j]);
@@ -293,7 +293,7 @@ const MainWindow = new Lang.Class({
row.uid = events[i].id;
widgetMap[uid] = row;
}
- widgetMap[uid].get_children()[0].label = message;
+ widgetMap[uid].get_children()[0].label = message.substring(index - 2);
}
this._widgetMap = widgetMap;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]