Clear Column for tweetdeck mac
replace these two files in the htdocs/web
- mustaches/mustaches.*.js
- scripts/swift/app/main.*.js
And the clear column action will appear in the title bar.
It doesn't override the 'mark all as read' action on messages, so on that column you will still need to open the column.
Otherwise, it uses the 'mark all as read' icon for the clear action.
wbyoko
-
install js-beautify globaly
npm -g install js-beautify
-
go to web directory
cd /Applications/TweetDeck.app/Contents/Resources/htdocs/web
-
pretty print templates and main js
cd scripts/swift/app/
sudo chmod 777 main.*
js-beautify -r main.*
cd ../../../mustaches/
this.TD_mustaches/g' mustaches.*```
- add isClearable and hasHeaderActions to templates / js
this.TD_mustaches["column/column_header.mustache"]= '
' + ' {{^isTemporary}} {{/isTemporary}} ' + ' ' + ' {{#isTemporary}} {{/isTemporary}} ' + ' {{^isTemporary}} {{/isTemporary}} ' + ' {{^withEditableTitle}} {{/withEditableTitle}} ' + ' {{#withEditableTitle}}- Add javascript to main.js file.
###Search Keys
- 'handleMarkAllRead'
add these lines to the action function variables
}, this.handleColumnClear = function() {
this.column.clear(), this.trigger("uiClearColumnAction", {
columnId: this.column.model.getKey()
});
add these lines to the event registration protion
, this.on("uiColumnClearAction", this.handleColumnClear)
- 'mark-all-read'
add these lines to the action switch
case "clear":
s.trigger("uiColumnClearAction", {
columnKey: n
});
break;
- 'column/column_header'
add these lines to the template variables object
hasHeaderAction: hA,
isClearable: iC,
add these lines to the end of the javascript right before the template variable object.
you have to find out the column parameter is mCol = ?
.
look for isMessageColumn()
method call a line up and find the object.
var mCol = ?,
cMes = mCol.isMessageColumn(),
iC = !cMes && mCol.isClearable(),
hA = cMes || iC;