Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(406)

Side by Side Diff: Source/core/html/HTMLLIElement.cpp

Issue 16599003: :hover style not applied on hover if its display property is different from original style's (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Patch (fixed test that was expected to fail and is now passing) Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/html/HTMLLIElement.h ('k') | Source/core/html/HTMLMediaElement.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2006, 2007, 2010 Apple Inc. All rights reserved. 4 * Copyright (C) 2006, 2007, 2010 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 77
78 void HTMLLIElement::parseAttribute(const QualifiedName& name, const AtomicString & value) 78 void HTMLLIElement::parseAttribute(const QualifiedName& name, const AtomicString & value)
79 { 79 {
80 if (name == valueAttr) { 80 if (name == valueAttr) {
81 if (renderer() && renderer()->isListItem()) 81 if (renderer() && renderer()->isListItem())
82 parseValue(value); 82 parseValue(value);
83 } else 83 } else
84 HTMLElement::parseAttribute(name, value); 84 HTMLElement::parseAttribute(name, value);
85 } 85 }
86 86
87 void HTMLLIElement::attach() 87 void HTMLLIElement::attach(const AttachContext& context)
88 { 88 {
89 ASSERT(!attached()); 89 ASSERT(!attached());
90 90
91 HTMLElement::attach(); 91 HTMLElement::attach(context);
92 92
93 if (renderer() && renderer()->isListItem()) { 93 if (renderer() && renderer()->isListItem()) {
94 RenderListItem* listItemRenderer = toRenderListItem(renderer()); 94 RenderListItem* listItemRenderer = toRenderListItem(renderer());
95 95
96 // Find the enclosing list node. 96 // Find the enclosing list node.
97 Element* listNode = 0; 97 Element* listNode = 0;
98 Element* current = this; 98 Element* current = this;
99 while (!listNode) { 99 while (!listNode) {
100 current = current->parentElement(); 100 current = current->parentElement();
101 if (!current) 101 if (!current)
(...skipping 17 matching lines...) Expand all
119 119
120 bool valueOK; 120 bool valueOK;
121 int requestedValue = value.toInt(&valueOK); 121 int requestedValue = value.toInt(&valueOK);
122 if (valueOK) 122 if (valueOK)
123 toRenderListItem(renderer())->setExplicitValue(requestedValue); 123 toRenderListItem(renderer())->setExplicitValue(requestedValue);
124 else 124 else
125 toRenderListItem(renderer())->clearExplicitValue(); 125 toRenderListItem(renderer())->clearExplicitValue();
126 } 126 }
127 127
128 } 128 }
OLDNEW
« no previous file with comments | « Source/core/html/HTMLLIElement.h ('k') | Source/core/html/HTMLMediaElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698