allowedBackground, (TermIdent) term); if (bp != null) storeBackgroundPosition(vv, bp, term); } else if (term instanceof TermPercent) { storeBackgroundPosition(vv, null, term); } else if (term instanceof TermLength) { storeBackgroundPosition(vv, null, term);
allowedBackground, (TermIdent) term); if (bp != null) storeBackgroundPosition(vv, bp, term); } else if (term instanceof TermPercent) { storeBackgroundPosition(vv, null, term); } else if (term instanceof TermLength) storeBackgroundPosition(vv, null, term);
private void storeBackgroundPosition(Term<?>[] storage, BackgroundPosition bp, Term<?> term) { if (bp == BackgroundPosition.LEFT) setPositionValue(storage, 0, tf.createPercent(0.0f)); else if (bp == BackgroundPosition.RIGHT) setPositionValue(storage, 0, tf.createPercent(100.0f)); else if (bp == BackgroundPosition.TOP) setPositionValue(storage, 1, tf.createPercent(0.0f)); else if (bp == BackgroundPosition.BOTTOM) setPositionValue(storage, 1, tf.createPercent(100.0f)); else if (bp == BackgroundPosition.CENTER) setPositionValue(storage, -1, tf.createPercent(50.0f)); else setPositionValue(storage, -1, term); }
private void storeBackgroundPosition(Term<?>[] storage, BackgroundPosition bp, Term<?> term) { if (bp == BackgroundPosition.LEFT) setPositionValue(storage, 0, tf.createPercent(0.0f)); else if (bp == BackgroundPosition.RIGHT) setPositionValue(storage, 0, tf.createPercent(100.0f)); else if (bp == BackgroundPosition.TOP) setPositionValue(storage, 1, tf.createPercent(0.0f)); else if (bp == BackgroundPosition.BOTTOM) setPositionValue(storage, 1, tf.createPercent(100.0f)); else if (bp == BackgroundPosition.CENTER) setPositionValue(storage, -1, tf.createPercent(50.0f)); else setPositionValue(storage, -1, term); }
@SuppressWarnings("unused") private boolean processBackgroundRepeat(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.REPEAT, d, properties, values); }
@SuppressWarnings("unused") private boolean processBackgroundColor(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.COLOR, d, properties, values); }
@SuppressWarnings("unused") private boolean processBackgroundRepeat(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.REPEAT, d, properties, values); }
@SuppressWarnings("unused") private boolean processBackgroundImage(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.IMAGE, d, properties, values); }
@SuppressWarnings("unused") private boolean processBackgroundAttachment(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.ATTACHMENT, d, properties, values); }
@SuppressWarnings("unused") private boolean processBackgroundImage(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.IMAGE, d, properties, values); }
@SuppressWarnings("unused") private boolean processBackgroundSize(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryMultiTermVariant(BackgroundVariator.SIZE, properties, values, d.toArray(new Term<?>[0])); }
@SuppressWarnings("unused") private boolean processBackgroundPosition(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryMultiTermVariant(BackgroundVariator.POSITION, properties, values, d.toArray(new Term<?>[0])); }
@SuppressWarnings("unused") private boolean processBackgroundAttachement(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.ATTACHEMENT, d, properties, values); }
@SuppressWarnings("unused") private boolean processBackground(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { Variator background = new BackgroundVariator(); background.assignTermsFromDeclaration(d); background.assignDefaults(properties, values); return background.vary(properties, values); }
@SuppressWarnings("unused") private boolean processBackground(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { Variator background = new BackgroundVariator(); background.assignTermsFromDeclaration(d); background.assignDefaults(properties, values); return background.vary(properties, values); }
@SuppressWarnings("unused") private boolean processBackgroundPosition(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryMultiTermVariant(BackgroundVariator.POSITION, properties, values, d.toArray(new Term<?>[0])); }
@SuppressWarnings("unused") private boolean processBackgroundColor(Declaration d, Map<String, CSSProperty> properties, Map<String, Term<?>> values) { final Variator background = new BackgroundVariator(); return background.tryOneTermVariant(BackgroundVariator.COLOR, d, properties, values); }