Skip to content

Commit 960a14e

Browse files
committed
* addSeconds -> addCDSeconds method name refactoring
1 parent 5f3d911 commit 960a14e

File tree

5 files changed

+16
-8
lines changed

5 files changed

+16
-8
lines changed

app/js/timer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ angular.module('timer', [])
8686
if ($scope.countdownattr) {
8787
$scope.millis = $scope.countdownattr * 1000;
8888

89-
$scope.addSeconds = $element[0].addSeconds = function( extraSeconds ){
89+
$scope.addCDSeconds = $element[0].addCDSeconds = function( extraSeconds ){
9090
$scope.countdown += extraSeconds;
9191
$scope.$digest();
9292
};

dist/angular-timer.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* angular-timer - v1.0.10 - 2014-01-04 8:31 PM
2+
* angular-timer - v1.0.10 - 2014-01-07 1:27 PM
33
* https://github.com/siddii/angular-timer
44
*
55
* Copyright (c) 2014 Siddique Hameed
@@ -93,7 +93,7 @@ angular.module('timer', [])
9393
if ($scope.countdownattr) {
9494
$scope.millis = $scope.countdownattr * 1000;
9595

96-
$scope.addSeconds = $element[0].addSeconds = function( extraSeconds ){
96+
$scope.addCDSeconds = $element[0].addCDSeconds = function( extraSeconds ){
9797
$scope.countdown += extraSeconds;
9898
$scope.$digest();
9999
};

dist/angular-timer.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/docs.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ function stopTimer(sectionId) {
77
}
88

99

10-
function addSeconds(sectionId, extraTime) {
11-
document.getElementById(sectionId).getElementsByTagName('timer')[0].addSeconds( extraTime );
10+
function addCDSeconds(sectionId, extraTime) {
11+
document.getElementById(sectionId).getElementsByTagName('timer')[0].addCDSeconds( extraTime );
1212
}
1313

1414
function stopResumeTimer(sectionId, btn) {

index.html

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ <h3>
130130
<h3>
131131
<timer countdown="100" interval="1000">{{countdown}}</timer>
132132
</h3>
133-
<button class="btn" onclick="addSeconds('countdown-timer', 10)" type="button">Add 10 Seconds</button>
133+
<button class="btn" onclick="addCDSeconds('countdown-timer', 10)" type="button">Add 10 Seconds</button>
134134
</div>
135135
</section>
136136
<section id="auto-start-false-timer">
@@ -277,6 +277,14 @@ <h4>
277277
Resumes the timer. Will NOT reset the start time
278278
</td>
279279
</tr>
280+
<tr>
281+
<td>
282+
addCDSeconds
283+
</td>
284+
<td>
285+
Add <i>seconds</i> to running countdown
286+
</td>
287+
</tr>
280288
</tbody>
281289
</table>
282290
<h4>

0 commit comments

Comments
 (0)