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

Add support for gtk2 gir files #54

Merged
merged 7 commits into from
Jul 24, 2018
Merged

Add support for gtk2 gir files #54

merged 7 commits into from
Jul 24, 2018

Conversation

decriptor
Copy link
Contributor

Instead of Deprecated being a bool it was used as the deprecation
message.

if (Deprecated)
writer.WriteLine ($"[Obsolete (\"(Version: {DeprecatedVersion}) {DocDeprecated.Text}\")]");

if (!string.IsNullOrEmpty (Deprecated)) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Which gobject-introspection version was used for these files? This might happen if the gi-scanner is too old and the gir format has changed.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The version claimed to be the same gir format version

[TestFixture]
public abstract class GenerationGtk2TestBase
{
protected const string Gdk2 = "Gtk2.Gdk-2.0";
Copy link
Contributor

Choose a reason for hiding this comment

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

Why not just add them into the generation test base?

Copy link
Contributor Author

@decriptor decriptor Mar 4, 2018

Choose a reason for hiding this comment

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

I started to do that, but the include directory is different. Might be worth merging them back together?

Copy link
Contributor

Choose a reason for hiding this comment

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

We can probably infer the include directory from the name? i.e. Gtk2.Gdk-2.0 -> include Gtk2, load Gdk-2.0.

writer.WriteLine ($"[Obsolete (\"(Version: {DeprecatedVersion}) {DocDeprecated.Text}\")]");

if (!string.IsNullOrEmpty (Deprecated)) {
if (Deprecated == "0") {
Copy link
Contributor

Choose a reason for hiding this comment

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

This check is redundant?

Copy link
Contributor

Choose a reason for hiding this comment

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

if (Deprecated == "1") -> obsolete version
else if (Deprecated != "0") -> obsolete

Instead of blindly parsing all of the available gir files we now
specify a specific library. In particular we are avoiding mixing
gtk2 and gtk3 gir files.
@Therzok Therzok merged commit a03154c into master Jul 24, 2018
@decriptor decriptor deleted the gtk2-gir-files branch July 24, 2018 20:28
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.

3 participants