
# react-native-statusbar-manager

## Installation

```sh
$ npm install react-native-statusbar-manager --save
$ react-native link react-native-statusbar-manager
```

## Usage

#### Attention

* The statusBar in this moudule is not the system statusBar.
* The theme of activity could not be set to `fitsSystemWindow = true`, must be set to `fitsSystemWindow=false`

### Example

```java

public class MainActivity extends AppCompatActivity {
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.test);
        RNStatusbarManagerModule.translucentStatusBar(this, true);
        View content = LayoutInflater.from(this).inflate(R.layout.test, null);
        RNStatusbarManagerModule.steepStatusbarView(this, content, android.R.color.white);
    }
}
```

Set avtivity to full screen with transparent background  statusbar and dark(or not) word（icon） in statusbar。

```java
 RNStatusbarManagerModule.translucentStatusBar(this, true);//or false
```

Set statusBar to color white backgroud:

```java
 RNStatusbarManagerModule.steepStatusbarView(this, content, android.R.color.white);
```

Set statusBar to color with alpha:

```java
RNStatusbarManagerModule.steepStatusbarView(this,content,0xcc,0x88);
```

Set activity looks like fitsSystemWindow = false or not:

```java
RNStatusbarManagerModule.steepStatusbarView(this,content,false);//or true
```
