我使用自定义样式资源并使用以下代码更改主题,更改操作栏和状态栏颜色但fab按钮主题不会更改。
Write a script that attempts to insert a new division named “Guitars” into the Division table. If the
insert is successful, the script should display this message:
SUCCESS: Record was inserted.
If the update is unsuccessful, the script should display a message something like this:
FAILURE: Record was not inserted.
Error 2627: Violation of UNIQUE KEY constraint
'UQ__Division__5A98D48EAD30FDC4'. Cannot insert duplicate key in object
'dbo.Division'. The duplicate key value is (Guitars).
答案 0 :(得分:1)
浮动操作按钮的颜色默认为public static void main(String args[]){
WebDriver driver = new FirefoxDriver();
driver.get("https://ecouncil.bayside.vic.gov.au/eservice/daEnquiryInit.do?docType=5&nodeNum=1118");
driver.get("https://ecouncil.bayside.vic.gov.au/eservice/daEnquiry.do?number=&lodgeRangeType=on&dateFrom=01%2F09%2F2017&dateTo=30%2F09%2F2017&detDateFromString=&detDateToString=&streetName=&suburb=0&unitNum=&houseNum=0%0D%0A%09%09%09%09%09&planNumber=&strataPlan=&lotNumber=&propertyName=&searchMode=A&submitButton=Search");
List<WebElement> keys = driver.findElements(By.xpath("//span[@class='key']"));
List<WebElement> inputFields = driver.findElements(By.xpath("//span[@class='inputField']"));
String var1, var2, var3;
for (int j = 0; j < keys.size(); j++) {
WebElement key = keys.get(j);
System.out.println("key: " + key.getText());
System.out.println("inputField: " + inputFields.get(j).getText());
if (key.getText().equalsIgnoreCase("Type of Work")) {
var1 = inputFields.get(j).getText();
System.out.println("var1: " + var1);
} else if (key.getText().equalsIgnoreCase("Application No.")) {
var2 = inputFields.get(j).getText();
System.out.println("var2: " + var2);
} else if (key.getText().equalsIgnoreCase("Date Lodged")) {
var3 = inputFields.get(j).getText();
System.out.println("var3: " + var3);
}
System.out.println("------------------" + j + "------------------");
}
}
,您可以从代码更改此内容。
colorAccent
上面代码中的valueOf方法采用 if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
fab.setBackgroundTintList(ColorStateList
.valueOf(getResources()
.getColor(colorsArray[themeId],getTheme())));
}
int