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

Side by Side Diff: Source/core/css/MediaQuery.h

Issue 16208004: No need to store invalid media queries. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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/css/MediaList.cpp ('k') | Source/core/css/MediaQuery.cpp » ('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 * CSS Media Query 2 * CSS Media Query
3 * 3 *
4 * Copyright (C) 2006 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>. 4 * Copyright (C) 2006 Kimmo Kinnunen <kimmo.t.kinnunen@nokia.com>.
5 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). 5 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 typedef Vector<OwnPtr<MediaQueryExp> > ExpressionVector; 47 typedef Vector<OwnPtr<MediaQueryExp> > ExpressionVector;
48 48
49 MediaQuery(Restrictor, const String& mediaType, PassOwnPtr<ExpressionVector> exprs); 49 MediaQuery(Restrictor, const String& mediaType, PassOwnPtr<ExpressionVector> exprs);
50 ~MediaQuery(); 50 ~MediaQuery();
51 51
52 Restrictor restrictor() const { return m_restrictor; } 52 Restrictor restrictor() const { return m_restrictor; }
53 const Vector<OwnPtr<MediaQueryExp> >* expressions() const { return m_express ions.get(); } 53 const Vector<OwnPtr<MediaQueryExp> >* expressions() const { return m_express ions.get(); }
54 String mediaType() const { return m_mediaType; } 54 String mediaType() const { return m_mediaType; }
55 bool operator==(const MediaQuery& other) const; 55 bool operator==(const MediaQuery& other) const;
56 String cssText() const; 56 String cssText() const;
57 bool ignored() const { return m_ignored; }
58 57
59 PassOwnPtr<MediaQuery> copy() const { return adoptPtr(new MediaQuery(*this)) ; } 58 PassOwnPtr<MediaQuery> copy() const { return adoptPtr(new MediaQuery(*this)) ; }
60 59
61 void reportMemoryUsage(MemoryObjectInfo*) const; 60 void reportMemoryUsage(MemoryObjectInfo*) const;
62 61
63 private: 62 private:
64 MediaQuery(const MediaQuery&); 63 MediaQuery(const MediaQuery&);
65 64
66 Restrictor m_restrictor; 65 Restrictor m_restrictor;
67 String m_mediaType; 66 String m_mediaType;
68 OwnPtr<ExpressionVector> m_expressions; 67 OwnPtr<ExpressionVector> m_expressions;
69 bool m_ignored;
70 String m_serializationCache; 68 String m_serializationCache;
71 69
72 String serialize() const; 70 String serialize() const;
73 }; 71 };
74 72
75 } // namespace 73 } // namespace
76 74
77 #endif 75 #endif
OLDNEW
« no previous file with comments | « Source/core/css/MediaList.cpp ('k') | Source/core/css/MediaQuery.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698