Use point icon for ng-click
This commit is contained in:
parent
b40ff4fb43
commit
ce22e44534
|
@ -200,7 +200,7 @@ input[type=text], input[type=password] {
|
|||
}
|
||||
|
||||
.color-gray {
|
||||
color: lightgray;
|
||||
color: lightgray;u
|
||||
}
|
||||
|
||||
.color-brown {
|
||||
|
@ -219,3 +219,8 @@ li.notification {
|
|||
color: green;
|
||||
}
|
||||
|
||||
[ng-click],
|
||||
[data-ng-click],
|
||||
[x-ng-click] {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
|
|
@ -69,7 +69,7 @@
|
|||
<input type="text" class="form-control" id="lines" ng-model="lines" placeholder="40">
|
||||
<p class="help-block">Enter number of lines to sync from WeeChat on connect</p>
|
||||
</div>
|
||||
<button class="btn btn-lg btn-primary" ng-click="connect()">Connect!</button>
|
||||
<button class="btn btn-lg btn-primary" ng-click="connect()">Connect <i class="glyphicon glyphicon-chevron-right"></i></button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -129,9 +129,14 @@
|
|||
<div class="brand pull-left">
|
||||
<img alt="brand" src="img/favicon.png">
|
||||
</div>
|
||||
<div class="title">
|
||||
<div class="title pull-left">
|
||||
{{ pageTitle}}
|
||||
</div>
|
||||
<div class="actions pull-right">
|
||||
<a ng-click="disconnect()">
|
||||
<i class="glyphicon glyphicon-remove"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div id="sidebar">
|
||||
<form class="form-inline" role="form">
|
||||
|
|
|
@ -410,6 +410,11 @@ weechat.factory('connection', ['$q', '$rootScope', '$log', '$store', 'handlers',
|
|||
this.websocket = websocket;
|
||||
}
|
||||
|
||||
var disconnect = function() {
|
||||
console.log(this.websocket);
|
||||
this.websocket.close();
|
||||
}
|
||||
|
||||
var sendMessage = function(message) {
|
||||
doSend(WeeChatProtocol.formatInput({
|
||||
buffer: models.getActiveBuffer()['fullName'],
|
||||
|
@ -421,6 +426,7 @@ weechat.factory('connection', ['$q', '$rootScope', '$log', '$store', 'handlers',
|
|||
return {
|
||||
send: doSend,
|
||||
connect: connect,
|
||||
disconnect: disconnect,
|
||||
sendMessage: sendMessage
|
||||
}
|
||||
}]);
|
||||
|
@ -509,6 +515,9 @@ weechat.controller('WeechatCtrl', ['$rootScope', '$scope', '$store', '$timeout',
|
|||
$scope.connect = function() {
|
||||
connection.connect($scope.host, $scope.port, $scope.password, $scope.ssl);
|
||||
}
|
||||
$scope.discconnect = function() {
|
||||
connection.disconnect();
|
||||
}
|
||||
|
||||
/* Function gets called from bufferLineAdded code if user should be notified */
|
||||
$rootScope.createHighlight = function(buffer, message) {
|
||||
|
|
Loading…
Reference in New Issue