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

Fixed int bug in column calculation of ObjectCollection #1678

Merged
merged 1 commit into from
Feb 2, 2018
Merged

Fixed int bug in column calculation of ObjectCollection #1678

merged 1 commit into from
Feb 2, 2018

Conversation

Weasy666
Copy link
Contributor

Column calculation was buggy because of some int math.
As an Example, when calculating columns with a NodeList.Count of 4 and Rows of 5 (both are int values) the result is 0. That resulted in all CollectionNodes being positioned in one place.

Column calculation was buggy because of some `int` math.  
As an Example, when calculating columns with a `NodeList.Count` of `4` and `Rows` of `5` (both are `int` values) the result is 0. That resulted in all CollectionNodes being positioned in one place.
@Weasy666
Copy link
Contributor Author

Please wait a moment before merging. I maybe found another bug.
Currently when i have 4 Objects in my collection and the LayoutType set to RowThanColumn shouldn't the 4 objects be positioned in one row/line? I get just a single column and changing the LayoutType to ColumnThanRow doesn't change a thing for me in the editor.

@StephenHodgson
Copy link
Contributor

Are you in play mode, or just in the editor?

@Weasy666
Copy link
Contributor Author

Just in the editor and pressing the Update Collection button.

@StephenHodgson
Copy link
Contributor

Make sure you use the execute in edit mode attribute.

@Weasy666
Copy link
Contributor Author

Weasy666 commented Jan 30, 2018

The Update button is working fine.
Shouldn't i get a row instead of a column here?
image

Here i'm getting a row, but it's kinda forced with Rows set to 1.
image

Edit:
Hm...I think i just misinterpreted it. Seems like the LayoutType is just for the layout order when there are more Objects than rows. I initially thought you could fill a row first and than go to the next, but because there is no max columns that is not possible with this script.
Sorry, my bad.

@keveleigh keveleigh merged commit 0390955 into microsoft:Dev_Working_Branch Feb 2, 2018
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

Successfully merging this pull request may close these issues.

3 participants