Skip to content
This repository was archived by the owner on Nov 26, 2020. It is now read-only.

Fixed code style#191

Merged
hebertialmeida merged 1 commit intoFolioReader:masterfrom
revolter:patch-2
Dec 9, 2016
Merged

Fixed code style#191
hebertialmeida merged 1 commit intoFolioReader:masterfrom
revolter:patch-2

Conversation

@revolter
Copy link
Copy Markdown
Member

@revolter revolter commented Dec 9, 2016

Extracted duplicate "hack" into a clearly named function. Previously, not all
instances had the explanation comment, and its side effect was not clear.

Extracted duplicate "hack" into a clearly named function. Previously, not all
instances had the explanation comment, and its side effect was not clear.
Copy link
Copy Markdown
Member

@hebertialmeida hebertialmeida left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much better, thanks...

// Forces text selection clearing
// @NOTE: this doesn't seem to always work

self.isUserInteractionEnabled = false
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't need to use self here.

isUserInteractionEnabled = false
isUserInteractionEnabled = true

self.clearTextSelection()
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't need to use self here.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know, but it's more consistent and clear this way.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am personally going by this answer:

I would prefer to keep using self whenever I'm using a property to omit these misunderstandings.

What do you think?

@hebertialmeida hebertialmeida merged commit 3377280 into FolioReader:master Dec 9, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants