Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android 4.3 and previous, clicking does not work. #12

Closed
slamadeleine opened this issue Mar 12, 2016 · 1 comment
Closed

Android 4.3 and previous, clicking does not work. #12

slamadeleine opened this issue Mar 12, 2016 · 1 comment

Comments

@slamadeleine
Copy link

I've incorporated this directive in Ionic 1.2.4 and it works perfect on Android 4.4+, iOS 8 and 9 but on some older devices 4.3 and 4.2 I can't get it to work. The stars show up but clicking them does not trigger the actions. I tried deconstructing the file and find a solution but I haven't found a workaround. Any insight as to where I should look? (I even tried to replace the ng-click directly to execute a simple action and it does not seem to be hooked).

Template

<div class="item item-text-wrap">
    <ionic-ratings ratingsobj='ratingsObject'></ionic-ratings>
</div>

Controller

$scope.ratingsObject = {
    iconOn: 'ion-ios-star',
    iconOff: 'ion-ios-star-outline',
    iconOnColor: 'rgb(248, 166, 30)',
    iconOffColor:  'rgb(30, 75, 100)',
    rating:  storage.getRating(id),
    minRating:0,
    readOnly: false,
    callback: function(rating) {
        $scope.ratingsCallback(id,rating);
    }
};
$scope.ratingsCallback = function(id,rating) {
    storage.setRating(id, rating);
    var alertPopup = $ionicPopup.alert({
        title: id,
        template: rating,
    });
    alertPopup.then(function(res) {     });
};
@rajeshwarpatlolla
Copy link
Owner

May the events in older version of android works in a different way. I started testing from android lollipop version, and there is no issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants