If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

Views should be created by the view manager

RESOLVED FIXED

Status

()

Core
Layout: View Rendering
RESOLVED FIXED
13 years ago
13 years ago

People

(Reporter: neil@parkwaycc.co.uk, Assigned: neil@parkwaycc.co.uk)

Tracking

Trunk
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Assignee)

Description

13 years ago
Currently views are created by the component manager. This is a hack that
depends on the component manager being able to call QueryInterface on a view,
thinking that it implements nsISupports. Instead the view manager should create
and initialize views directly.
(Assignee)

Comment 1

13 years ago
Created attachment 164280 [details] [diff] [review]
Remove NS_VIEW_CID
Assignee: roc → neil.parkwaycc.co.uk
Status: NEW → ASSIGNED
(Assignee)

Updated

13 years ago
Attachment #164280 - Flags: superreview?(roc)
Attachment #164280 - Flags: review?(roc)
   { "Scroll Port View", NS_SCROLL_PORT_VIEW_CID,
     "@mozilla.org/scroll-port-view;1", nsScrollPortViewConstructor },
 
can you remove this too?
also, is nsIView::Init still needed?
(Assignee)

Comment 4

13 years ago
(In reply to comment #2)
>    { "Scroll Port View", NS_SCROLL_PORT_VIEW_CID,
>      "@mozilla.org/scroll-port-view;1", nsScrollPortViewConstructor },
>  
> can you remove this too?
Not yet, but I can roll it into the patch...

(In reply to comment #3)
> also, is nsIView::Init still needed?
No, I'll remove that at the same time.
(Assignee)

Comment 5

13 years ago
Created attachment 164373 [details] [diff] [review]
Proposed patch

OK, so now I've fixed up scrollable and placeholder views too.
I've also removed a few includes that are no longer used.

Note that ViewWrapper still uses of nsIView::QueryInterface; the other callers
need to be replaced by nsIView::GetScrollableView (or IsScrollableView or
whatever the flavour of the month is).
(Assignee)

Updated

13 years ago
Attachment #164373 - Flags: superreview?(roc)
Attachment #164373 - Flags: review?(roc)
(Assignee)

Comment 6

13 years ago
Oh wait, I'll need to rev some IIDs too, sigh...
Comment on attachment 164373 [details] [diff] [review]
Proposed patch

bump the IIDs
Attachment #164373 - Flags: superreview?(roc)
Attachment #164373 - Flags: superreview+
Attachment #164373 - Flags: review?(roc)
Attachment #164373 - Flags: review+
Attachment #164280 - Flags: superreview?(roc)
Attachment #164280 - Flags: review?(roc)
(Assignee)

Comment 8

13 years ago
Fix checked in.
Status: ASSIGNED → RESOLVED
Last Resolved: 13 years ago
Resolution: --- → FIXED

Comment 9

13 years ago
Seems that Camino has started to have some serious scrolling issues after this
bug was fixed. A separate Camino bug was filed to track what happened, Bug Bug
268218.
You need to log in before you can comment on or make changes to this bug.