зеркало из https://github.com/mozilla/gecko-dev.git
(no bug) Replace two c-style casts in nsFrame.cpp with const_cast<>. (no review; trivial/non-functional)
This commit is contained in:
Родитель
3491cda560
Коммит
f0029d8a39
|
@ -2507,7 +2507,7 @@ nsFrame::IsSelectable(bool* aSelectable, uint8_t* aSelectStyle) const
|
|||
// AUTO -> CELL -> TEXT -> AUTO, the returned value is TEXT
|
||||
//
|
||||
uint8_t selectStyle = NS_STYLE_USER_SELECT_AUTO;
|
||||
nsIFrame* frame = (nsIFrame*)this;
|
||||
nsIFrame* frame = const_cast<nsFrame*>(this);
|
||||
|
||||
while (frame) {
|
||||
const nsStyleUIReset* userinterface = frame->StyleUIReset();
|
||||
|
@ -4518,7 +4518,7 @@ NS_IMETHODIMP nsFrame::GetOffsetFromView(nsPoint& aOffset,
|
|||
nsView** aView) const
|
||||
{
|
||||
NS_PRECONDITION(nullptr != aView, "null OUT parameter pointer");
|
||||
nsIFrame* frame = (nsIFrame*)this;
|
||||
nsIFrame* frame = const_cast<nsFrame*>(this);
|
||||
|
||||
*aView = nullptr;
|
||||
aOffset.MoveTo(0, 0);
|
||||
|
|
Загрузка…
Ссылка в новой задаче