From 6ca324f8b591f9f811acb600faabb3567ddb6125 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Tue, 5 Jun 2018 21:13:04 +0200 Subject: [PATCH] style: Remove unused PropertyDeclarationBlock::set_importance. Bug: 1466963 Reviewed-by: xidorn MozReview-Commit-ID: 1YrlOvktag9 --- .../style/properties/declaration_block.rs | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/components/style/properties/declaration_block.rs b/components/style/properties/declaration_block.rs index e192d08b22d..c88458d0fd9 100644 --- a/components/style/properties/declaration_block.rs +++ b/components/style/properties/declaration_block.rs @@ -564,23 +564,6 @@ impl PropertyDeclarationBlock { true } - /// Set the declaration importance for a given property, if found. - /// - /// Returns whether any declaration was updated. - pub fn set_importance(&mut self, property: &PropertyId, new_importance: Importance) -> bool { - let mut updated_at_least_one = false; - for (i, declaration) in self.declarations.iter().enumerate() { - if declaration.id().is_or_is_longhand_of(property) { - let is_important = new_importance.important(); - if self.declarations_importance[i] != is_important { - self.declarations_importance.set(i, is_important); - updated_at_least_one = true; - } - } - } - updated_at_least_one - } - /// /// /// Returns whether any declaration was actually removed.