diff options
| author | Caitlin Potter | 2014-02-21 14:31:23 -0500 |
|---|---|---|
| committer | Caitlin Potter | 2014-02-21 14:52:12 -0500 |
| commit | 2f4513339337bb8aa6c9dfe1191d169b4fc57999 (patch) | |
| tree | ce0d47cee3d490c907cef680cc12e131f2a1cbf9 /example/buzz/buzz.js | |
| parent | 4a6a3ba7fb08ce99007893ef75365a3e8aff938a (diff) | |
| download | angular.js-2f4513339337bb8aa6c9dfe1191d169b4fc57999.tar.bz2 | |
chore(examples): remove ancient examples from the tree
Let these poor scripts retire, goodness.
Closes #6398
Closes #3310
Diffstat (limited to 'example/buzz/buzz.js')
| -rw-r--r-- | example/buzz/buzz.js | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/example/buzz/buzz.js b/example/buzz/buzz.js deleted file mode 100644 index 7e7f2f66..00000000 --- a/example/buzz/buzz.js +++ /dev/null @@ -1,46 +0,0 @@ -angular.module.ng('myApplication', function($resource){ - this.Activity = $resource( - 'https://www.googleapis.com/buzz/v1/activities/:userId/:visibility/:activityId/:comments', - {alt:'json', callback:'JSON_CALLBACK'}, - { - get: {method:'JSON', params:{visibility:'@self'}}, - replies: {method:'JSON', params:{visibility:'@self', comments:'@comments'}} - }); -}, {inject:['$resource']}); - -function BuzzController() { - this.$watch('$location.hashPath', this.userChange); -} -BuzzController.prototype = { - userChange: function() { - this.userId = this.$location.hashPath; - this.activities = this.Activity.get({userId:this.userId}); - }, - - expandReplies: function(activity) { - var self = this; - if (activity.replies) { - activity.replies.show = !activity.replies.show; - } else { - activity.replies = this.Activity.replies({userId:this.userId, activityId:activity.id}, function() { - activity.replies.show = true; - }); - } - } -}; - -angular.widget('my:expand', function(element){ - element.css('display', 'block'); - this.descend(true); - return function(element) { - element.hide(); - var watch = element.attr('expand'); - this.$watch(watch, function(value){ - if (value) { - element.delay(0).slideDown('slow'); - } else { - element.slideUp('slow'); - } - }); - }; -}); |
