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

你的示例程序的控制器中写错了一个地方 #30

Open
SPStore opened this issue Nov 24, 2017 · 0 comments
Open

你的示例程序的控制器中写错了一个地方 #30

SPStore opened this issue Nov 24, 2017 · 0 comments

Comments

@SPStore
Copy link

SPStore commented Nov 24, 2017

`
for (int i = 0; i < activityTypes.count; i++) {

    DGActivityIndicatorView *activityIndicatorView = [[DGActivityIndicatorView alloc] initWithType:(DGActivityIndicatorAnimationType)[activityTypes[i] integerValue] tintColor:[UIColor whiteColor]];
    CGFloat width = self.view.bounds.size.width / 5.0f;
    CGFloat height = self.view.bounds.size.height / 7.0f;
    activityIndicatorView.frame = CGRectMake(width * (i % 7), height * (int)(i / 7), width, height);
    [self.view addSubview:activityIndicatorView];
    [activityIndicatorView startAnimating];

}`

宽度应该是除以7,不是除以5

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

1 participant