OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. |
3 * Copyright (C) 2010 Google Inc. All rights reserved. | 3 * Copyright (C) 2010 Google Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 426 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
437 } | 437 } |
438 } | 438 } |
439 | 439 |
440 // -------------------------------- | 440 // -------------------------------- |
441 | 441 |
442 inline SliderContainerElement::SliderContainerElement(Document& document) | 442 inline SliderContainerElement::SliderContainerElement(Document& document) |
443 : HTMLDivElement(document) | 443 : HTMLDivElement(document) |
444 { | 444 { |
445 } | 445 } |
446 | 446 |
447 PassRefPtrWillBeRawPtr<SliderContainerElement> SliderContainerElement::create(Do
cument& document) | 447 DEFINE_NODE_FACTORY(SliderContainerElement) |
448 { | |
449 return adoptRefWillBeRefCountedGarbageCollected(new SliderContainerElement(d
ocument)); | |
450 } | |
451 | 448 |
452 RenderObject* SliderContainerElement::createRenderer(RenderStyle*) | 449 RenderObject* SliderContainerElement::createRenderer(RenderStyle*) |
453 { | 450 { |
454 return new RenderSliderContainer(this); | 451 return new RenderSliderContainer(this); |
455 } | 452 } |
456 | 453 |
457 const AtomicString& SliderContainerElement::shadowPseudoId() const | 454 const AtomicString& SliderContainerElement::shadowPseudoId() const |
458 { | 455 { |
459 DEFINE_STATIC_LOCAL(const AtomicString, mediaSliderContainer, ("-webkit-medi
a-slider-container", AtomicString::ConstructFromLiteral)); | 456 DEFINE_STATIC_LOCAL(const AtomicString, mediaSliderContainer, ("-webkit-medi
a-slider-container", AtomicString::ConstructFromLiteral)); |
460 DEFINE_STATIC_LOCAL(const AtomicString, sliderContainer, ("-webkit-slider-co
ntainer", AtomicString::ConstructFromLiteral)); | 457 DEFINE_STATIC_LOCAL(const AtomicString, sliderContainer, ("-webkit-slider-co
ntainer", AtomicString::ConstructFromLiteral)); |
461 | 458 |
462 if (!shadowHost() || !shadowHost()->renderer()) | 459 if (!shadowHost() || !shadowHost()->renderer()) |
463 return sliderContainer; | 460 return sliderContainer; |
464 | 461 |
465 RenderStyle* sliderStyle = shadowHost()->renderer()->style(); | 462 RenderStyle* sliderStyle = shadowHost()->renderer()->style(); |
466 switch (sliderStyle->appearance()) { | 463 switch (sliderStyle->appearance()) { |
467 case MediaSliderPart: | 464 case MediaSliderPart: |
468 case MediaSliderThumbPart: | 465 case MediaSliderThumbPart: |
469 case MediaVolumeSliderPart: | 466 case MediaVolumeSliderPart: |
470 case MediaVolumeSliderThumbPart: | 467 case MediaVolumeSliderThumbPart: |
471 case MediaFullScreenVolumeSliderPart: | 468 case MediaFullScreenVolumeSliderPart: |
472 case MediaFullScreenVolumeSliderThumbPart: | 469 case MediaFullScreenVolumeSliderThumbPart: |
473 return mediaSliderContainer; | 470 return mediaSliderContainer; |
474 default: | 471 default: |
475 return sliderContainer; | 472 return sliderContainer; |
476 } | 473 } |
477 } | 474 } |
478 | 475 |
479 } | 476 } |
OLD | NEW |