Skip to content

Commit

Permalink
fix(android): expose properties for get/set pairs on QuickSettingsSer…
Browse files Browse the repository at this point in the history
…vice
  • Loading branch information
sgtcoolguy committed Feb 12, 2021
1 parent e69d13c commit b21ece2
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ public void updateTile()

//Setting Tile's icon
@Kroll.method
@Kroll.setProperty
public void setIcon(Object path)
{
tileService.getQsTile().setIcon(Icon.createWithBitmap(
Expand All @@ -52,34 +53,39 @@ public void setIcon(Object path)

//Setting Tile's state
@Kroll.method
@Kroll.setProperty
public void setState(int state)
{
tileService.getQsTile().setState(state);
}

//Setting Tile's label
@Kroll.method
@Kroll.setProperty
public void setLabel(String label)
{
tileService.getQsTile().setLabel(label);
}

//Getting Tile'c icon
@Kroll.method
@Kroll.getProperty
public Object getIcon()
{
return pathObject;
}

//Getting Tile's state
@Kroll.method
@Kroll.getProperty
public int getState()
{
return tileService.getQsTile().getState();
}

//Getting Tile's label
@Kroll.method
@Kroll.getProperty
public String getLabel()
{
return tileService.getQsTile().getLabel().toString();
Expand Down

0 comments on commit b21ece2

Please sign in to comment.