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

Request: Type Definition in Unit VirtualTrees.pas #1162

Closed
kxMaxx opened this issue Jan 10, 2023 · 7 comments
Closed

Request: Type Definition in Unit VirtualTrees.pas #1162

kxMaxx opened this issue Jan 10, 2023 · 7 comments
Assignees
Milestone

Comments

@kxMaxx
Copy link

kxMaxx commented Jan 10, 2023

Hi,

I would like to inquire on the Breaking Changes are really necessary.

The VirtualTree V8 code includes a new unit VirtualTrees.BaseTree.pas, which defines basic types (e.g. TVirtualNode and PVirtualNode). These types were previously in the VirtualTrees.pas unit.

If you install the current VirtualTree V8 state into the IDE and want to build old existing projects with it, this is not possible anymore, because these basic types are not found anymore. You have to adjust manually and add the new unit VirtualTrees.BaseTree.pas in the uses clause. This means: change of all old projects.

I would like to bypass this task and ask for a compatible solution in the VirtualTree project.
This would be a lot of work that will affect many projects worldwide.

Suggestion: use Include files in VirtualTrees.pas.

Thanks.

@joachimmarder
Copy link
Contributor

These changes were done by @livius2 for creating the FMX port of Virtual TreeView. Please use issue #1134 for discussion of changes in this context.

@livius2
Copy link
Contributor

livius2 commented Jan 11, 2023

We probably can add alias in VirtualTrees.pas

  PVirtualNode = VirtualTrees.BaseTree.PVirtualNode;
  TVirtualNode = VirtualTrees.BaseTree.TVirtualNode;

@joachimmarder what do you think? Any drawbacks?

@joachimmarder
Copy link
Contributor

I'm not aware of any drawbacks and use aliases frequently.

@joachimmarder
Copy link
Contributor

Let me know if there is any other important type affected.

@joachimmarder joachimmarder reopened this Jan 16, 2023
@joachimmarder
Copy link
Contributor

@livius2 : Many simple types are defined in the unit VirtualTrees.BaseTree, but simple types should better be placed in unit VirtualTrees.Types in my opinion. Is there anything that speaks against this?

That would make switching between V7 and V8 much easier.

@livius2
Copy link
Contributor

livius2 commented Jan 17, 2023

Is there anything that speaks against this?

Only circular unit reference nothing more.

joachimmarder added a commit that referenced this issue Feb 2, 2023
Move more simple types to VirtualTrees.Types in order to reduce breaking changes in V8.
@joachimmarder
Copy link
Contributor

It should be possible to reduce the amount of breaking changes to what is already documented in the Wiki.

joachimmarder added a commit that referenced this issue Feb 2, 2023
Move more simple types to VirtualTrees.Types and add aliases in VirtualTrees.pas in order to reduce breaking changes in V8.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants