forked from fanruan/demo-show-charts
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
799 B
34 lines
799 B
package com.fr.plugin.demo; |
|
|
|
import com.fr.extended.chart.ExtendedTypePane; |
|
|
|
/** |
|
* Created by shine on 2018/4/19. |
|
*/ |
|
public class DemoTypePane extends ExtendedTypePane<DemoChart> { |
|
@Override |
|
protected String[] getTypeIconPath() { |
|
return new String[]{ |
|
"com/fr/plugin/demo/dark.png", |
|
"com/fr/plugin/demo/white.png" |
|
}; |
|
} |
|
|
|
@Override |
|
protected String[] getTypeTipName() { |
|
return new String[]{ |
|
"深色主题", |
|
"浅色主题" |
|
}; |
|
} |
|
|
|
@Override |
|
protected int getTypeIndex(DemoChart chart) { |
|
return chart.getThemeType().ordinal(); |
|
} |
|
|
|
@Override |
|
protected void setType(DemoChart chart, int index) { |
|
chart.setThemeType(ThemeType.parseInt(index)); |
|
} |
|
}
|
|
|