Bug 200853 - Traditional Memory Rendering refactoring request
Summary: Traditional Memory Rendering refactoring request
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: DD (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: DD General Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
Depends on:
Blocks:
 
Reported: 2007-08-22 14:04 EDT by Alain Lee CLA
Modified: 2010-10-14 15:21 EDT (History)
3 users (show)

See Also:


Attachments
Refactoring (13.32 KB, text/java)
2007-08-22 14:06 EDT, Alain Lee CLA
no flags Details
Refactoring (43.62 KB, text/java)
2007-08-22 14:07 EDT, Alain Lee CLA
no flags Details
Refactoring (63.29 KB, text/java)
2007-08-22 14:07 EDT, Alain Lee CLA
no flags Details
additional changes for Rendering.java (1.94 KB, patch)
2007-10-31 12:46 EDT, Alain Lee CLA
no flags Details | Diff
TraditionalMemoryByte.java (424 bytes, patch)
2007-10-31 12:50 EDT, Alain Lee CLA
no flags Details | Diff
changes in TraditionalRendering.java (44.90 KB, patch)
2007-10-31 12:58 EDT, Alain Lee CLA
no flags Details | Diff
changes in DataPane.java (13.28 KB, patch)
2007-10-31 13:00 EDT, Alain Lee CLA
no flags Details | Diff
patch for DataPane.java (4.76 KB, patch)
2007-10-31 15:42 EDT, Alain Lee CLA
no flags Details | Diff
patch for Rendering.java (12.80 KB, text/plain)
2007-10-31 15:44 EDT, Alain Lee CLA
no flags Details
patch for TraditionalRendering.java (1.86 KB, patch)
2007-10-31 15:45 EDT, Alain Lee CLA
no flags Details | Diff
new file TraditionalMemoryByte.java (1.25 KB, patch)
2007-10-31 15:48 EDT, Alain Lee CLA
no flags Details | Diff
patch for Rendering.java (13.29 KB, patch)
2007-10-31 16:43 EDT, Alain Lee CLA
no flags Details | Diff
patch for Rendering.java (+committed, +logged) (13.33 KB, patch)
2007-11-05 16:51 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
patch for AbstractPane.java (+committed, +logged) (1.37 KB, patch)
2007-11-05 16:52 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
patch for DataPane.java (+committed, +logged) (4.74 KB, patch)
2007-11-05 16:52 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
patch for AddressPane.java (+committed, +logged) (1.57 KB, patch)
2007-11-06 11:49 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
patch for TextPane.java (+committed, +logged) (4.10 KB, patch)
2007-11-06 12:20 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
patch AbstractPane.java (+committed, +logged) (22.28 KB, patch)
2008-01-17 12:30 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
new file (+committed, +logged) (967 bytes, patch)
2008-01-17 12:32 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
new file (+committed, +logged) (1.49 KB, patch)
2008-01-17 12:32 EST, Alain Lee CLA
pawel.1.piech: iplog+
Details | Diff
additonal patch for Rendering.java (15.03 KB, text/plain)
2008-01-17 12:33 EST, Alain Lee CLA
no flags Details
additional patch for TraditionalRendering.java (1.58 KB, patch)
2008-01-17 12:33 EST, Alain Lee CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alain Lee CLA 2007-08-22 14:04:58 EDT
We plan to create our own rendering by extending from TraditionalRendering. To do this, we need to refactor the Traditional Rendering code a little bit and to change some methods from protected to public. Please review the attached changes.
Comment 1 Alain Lee CLA 2007-08-22 14:06:33 EDT
Created attachment 76681 [details]
Refactoring
Comment 2 Alain Lee CLA 2007-08-22 14:07:02 EDT
Created attachment 76682 [details]
Refactoring
Comment 3 Alain Lee CLA 2007-08-22 14:07:45 EDT
Created attachment 76683 [details]
Refactoring
Comment 4 Alain Lee CLA 2007-10-31 12:46:10 EDT
Created attachment 81737 [details]
additional changes for Rendering.java

Allow extensions to provide custom handling of debug devents
Comment 5 Alain Lee CLA 2007-10-31 12:50:14 EDT
Created attachment 81738 [details]
TraditionalMemoryByte.java

Move TraditionalMemoryByte class from TraditionalRendering.java to a separate file
Comment 6 Alain Lee CLA 2007-10-31 12:58:44 EDT
Created attachment 81742 [details]
changes in TraditionalRendering.java
Comment 7 Alain Lee CLA 2007-10-31 13:00:09 EDT
Created attachment 81743 [details]
changes in DataPane.java
Comment 8 Ted Williams CLA 2007-10-31 13:02:40 EDT
Please attach a patch. Without a patch, accurately determining the changes is problematic. 
Comment 9 Alain Lee CLA 2007-10-31 13:08:30 EDT
(In reply to comment #8)
> Please attach a patch. Without a patch, accurately determining the changes is
> problematic. 

I have included the changes for TraditionalRendering.java, DataPane.java, Rendering.java and TraditionalMemoryByte.java
Comment 10 Alain Lee CLA 2007-10-31 15:42:54 EDT
Created attachment 81768 [details]
patch for DataPane.java
Comment 11 Alain Lee CLA 2007-10-31 15:44:12 EDT
Created attachment 81769 [details]
patch for Rendering.java
Comment 12 Alain Lee CLA 2007-10-31 15:45:56 EDT
Created attachment 81770 [details]
patch for TraditionalRendering.java
Comment 13 Alain Lee CLA 2007-10-31 15:48:15 EDT
Created attachment 81771 [details]
new file TraditionalMemoryByte.java

Moved TraditionalMemoryByte to a separate file
Comment 14 Alain Lee CLA 2007-10-31 16:43:52 EDT
Created attachment 81782 [details]
patch for Rendering.java
Comment 15 Alain Lee CLA 2007-11-05 16:51:50 EST
Created attachment 82132 [details]
patch for Rendering.java (+committed, +logged)
Comment 16 Alain Lee CLA 2007-11-05 16:52:24 EST
Created attachment 82133 [details]
patch for AbstractPane.java (+committed, +logged)
Comment 17 Alain Lee CLA 2007-11-05 16:52:48 EST
Created attachment 82134 [details]
patch for DataPane.java (+committed, +logged)
Comment 18 Ted Williams CLA 2007-11-05 23:56:21 EST
I've reviewed this patch. It looks good. I'm ready to commit it, but I need to discuss timing with Pawel.
Comment 19 Alain Lee CLA 2007-11-06 11:49:42 EST
Created attachment 82219 [details]
patch for AddressPane.java (+committed, +logged)
Comment 20 Alain Lee CLA 2007-11-06 12:20:13 EST
Created attachment 82223 [details]
patch for TextPane.java (+committed, +logged)
Comment 21 Alain Lee CLA 2007-11-06 12:23:10 EST
Ted, I just added two more files for you to review. They allow extensions to peform their own coloring
Comment 22 Ted Williams CLA 2007-11-25 23:39:37 EST
Alain, the proposed changes (sans some comments) have been committed to HEAD with one exception.

You requested that we expose selection by means of three new methods to Rendering.java:

+    // added these methods to allow subclasses to access the selection
+    public BigInteger getSelectionStart()
+    {
+    	return this.getSelection().getStart();
+    }
+    
+    public BigInteger getSelectionEnd()
+    {
+    	return this.getSelection().getEnd();
+    }
+    
+    public boolean isAddressSelected(BigInteger address)
+    {
+    	return this.getSelection().isSelected(address);
+    }

Instead, to better allow for the selection to be represented by more than a single BigInteger in the future, I have exposed the selection by addition of an IMemorySelection interface. Rendering.getSelection() now returns IMemorySelection instead of Rendering.Selection.

Please verify.

Comment 23 Alain Lee CLA 2008-01-17 12:30:51 EST
Created attachment 87173 [details]
patch AbstractPane.java (+committed, +logged)

additional changes
Comment 24 Alain Lee CLA 2008-01-17 12:32:08 EST
Created attachment 87176 [details]
new file (+committed, +logged)
Comment 25 Alain Lee CLA 2008-01-17 12:32:34 EST
Created attachment 87177 [details]
new file (+committed, +logged)
Comment 26 Alain Lee CLA 2008-01-17 12:33:04 EST
Created attachment 87178 [details]
additonal patch for Rendering.java

additional changes
Comment 27 Alain Lee CLA 2008-01-17 12:33:49 EST
Created attachment 87179 [details]
additional patch for TraditionalRendering.java

additonal changes
Comment 28 Alain Lee CLA 2008-01-17 12:34:49 EST
Ted, please review the latest patches I submitted. Thanks!
Comment 29 Ted Williams CLA 2008-01-17 14:02:06 EST
hi Alain,

Thanks for the patches! I have two requests:

1) We should file this request under a new bugzilla, since this one is already fixed/resolved.

2) When you create the patch, use the workspace as the root. This will result in a single patch file with all of your changes.

Right click on the project in the package explorer.
Team -> Create Patch
File: patchname.txt
In the "Changes" list, all of your modified files should be checked.
Next
select Unified
select Workspace
Finish

ted