Opened 2 years ago

Closed 22 months ago

Last modified 13 months ago

#14821 closed bug (fixed)

In stand-alone window, add "Uninstall" button when applicable

Reported by: humdinger Owned by: leavengood
Priority: normal Milestone: R1/beta2
Component: Applications/HaikuDepot Version: R1/Development
Keywords: Cc:
Blocked By: Blocking: #15154
Platform: All


This is hrev52739.

When you double-click a HPKG, it's opened in a stand-alone HaikuDepot window. Here, you'll always get an "Install" button, even if the package is already installed. In that case, it should show an "Uninstall" button instead.

Change History (6)

comment:1 by taos, 2 years ago

Oh, and maybe close the window after a successful installation or give another indication (e.g. change "Install" to "Uninstall") that everything (incl. dependencies) is installed...

comment:2 by leavengood, 22 months ago

I started digging into this, and it seems when loading a package file in this way, the "state" of the PackageInfo in HaikuDepot is never initialized, and when that is the case the install button is shown.

HaikuDepot and the Package Kit is new to me but it does not seem obvious how to determine if a package is installed. The BPackageInfo from the package kit doesn't seem to contain that information. I imagine the code has to query something else to determine the state of the package but my Linux machine locked up before I could dig much further, and it is getting late for me.

I may dig into this more later this week.

comment:3 by diver, 22 months ago

Blocking: 15154 added

comment:4 by leavengood, 22 months ago

Owner: changed from stippi to leavengood
Status: newin-progress

comment:5 by leavengood, 22 months ago

Resolution: fixed
Status: in-progressclosed

Merged in hrev53354.

comment:6 by nielx, 13 months ago

Milestone: UnscheduledR1/beta2

Assign tickets with status=closed and resolution=fixed within the R1/beta2 development window to the R1/beta2 Milestone

Note: See TracTickets for help on using tickets.