This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 117890

Summary: Refreshing of "Update Target" in Status view
Product: versioncontrol Reporter: Peter Pis <ppis>
Component: MercurialAssignee: issues@versioncontrol <issues>
Status: VERIFIED FIXED    
Severity: blocker    
Priority: P3    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:
Attachments: proposed patch
new patch

Description Peter Pis 2007-10-05 10:55:26 UTC
Product Version: NetBeans IDE Dev (Build 200710050000)
Java: 1.6.0_02; Java HotSpot(TM) Client VM 1.6.0_02-b05
System: Windows XP version 5.1 running on x86; Cp1252; en_GB (nb)
Userdir: D:\ide\60daily\user

Steps:
1. Clone project and have it opened in NB.
2. Modify some file and commit changes.
3. Select project root and invoke "Mercurial | Status" action. "Mercurial view - Update Target: 2 (...)"
4. Selecting project root invoke "Mercurial | Export Diff" from main menu (use the latest revision)
5. For project root invoke "Mercurial | Rollback". Confirm upcoming dialog. "Mercurial view - Update Target: 2 (...)".
Pushing "Refresh" button in "Status" view makes "Mercurial view - Update Target: 1 (...)". This field should be
refreshed automatically

6. Selecting project root invoke "Mercurial | Import Patches" from main menu. Choose that file.
Mercurial view - Update Target: 1 (...)". Pushing "Refresh" button in "Status" view makes "Mercurial view - Update
Target: 2 (...)". This field should be refreshed automatically
Comment 1 Padraig Obriain 2007-10-16 16:28:49 UTC
The problem is that when rollback is done there are no files whose status changed so VersioningPanel is not notified.

As soon as a file changes status the fields are updated.
Comment 2 Padraig Obriain 2007-10-17 15:43:39 UTC
Created attachment 51126 [details]
proposed patch
Comment 3 Padraig Obriain 2007-10-22 18:36:32 UTC
IDE:-------------------------------------------------
IDE: [10/22/07 6:35 PM] Committing Files started
Checking in ui/rollback/RollbackAction.java;
/shared/data/ccvs/repository/versioncontrol/mercurial/src/org/netbeans/modules/mercurial/ui/rollback/RollbackAction.java,v
 <--  RollbackAction.java
new revision: 1.10; previous revision: 1.9
done
Checking in ui/diff/ImportDiffAction.java;
/shared/data/ccvs/repository/versioncontrol/mercurial/src/org/netbeans/modules/mercurial/ui/diff/ImportDiffAction.java,v
 <--  ImportDiffAction.java
new revision: 1.9; previous revision: 1.8
done
Checking in ui/status/VersioningPanel.java;
/shared/data/ccvs/repository/versioncontrol/mercurial/src/org/netbeans/modules/mercurial/ui/status/VersioningPanel.java,v
 <--  VersioningPanel.java
new revision: 1.8; previous revision: 1.7
done
Checking in Mercurial.java;
/shared/data/ccvs/repository/versioncontrol/mercurial/src/org/netbeans/modules/mercurial/Mercurial.java,v  <-- 
Mercurial.java
new revision: 1.13; previous revision: 1.12
done
IDE: [10/22/07 6:35 PM] Committing Files finished
Comment 4 Peter Pis 2007-11-16 13:08:15 UTC
Reopen, "Mercurial view - Update Target:" is still not refreshed.
Comment 5 Padraig Obriain 2007-11-16 14:13:31 UTC
I find that after Rollback then Update Target is updated but not after Import Patches.

Is this what you see?
Comment 6 Peter Pis 2007-11-16 14:20:54 UTC
For me, it's also reproducible after Rollback. Refresh button has to be pushed for seeing current status.
Comment 7 Padraig Obriain 2007-11-16 14:42:07 UTC
Yes. It does happen for Rollback. I am not sure why I thought it did not.

Comment 8 Padraig Obriain 2007-11-16 14:45:16 UTC
Created attachment 53127 [details]
new patch
Comment 9 Padraig Obriain 2007-11-19 11:54:43 UTC
Patch committed to HEAD.
Comment 10 Padraig Obriain 2007-11-19 12:00:04 UTC
IDE:-------------------------------------------------
IDE: [11/19/07 11:54 AM] Committing "VersioningPanel.java" started
Checking in VersioningPanel.java;
/shared/data/ccvs/repository/versioncontrol/mercurial/src/org/netbeans/modules/mercurial/ui/status/VersioningPanel.java,v
 <--  VersioningPanel.java
new revision: 1.12; previous revision: 1.11
done
IDE: [11/19/07 11:54 AM] Committing "VersioningPanel.java" finished

Comment 11 Peter Pis 2007-12-10 06:09:43 UTC
Verified.