Charge battery through the transistor
This circuit will never work, as the base-emitter junction is back-biased. When SW1 is closed, the emitter sees the full 3.7 volts, while the base sees only a fraction of this voltage as determined by R1R2. For the circuit to work, disconnect R1 from the emitter and connect it to the collector. This will make sure the base is more positive than the emitter (if you design voltage divider R1R2 correctly). Here's how I would modify your circuit.

[Edit] That said, I should emphasize that you should be extra careful when charging lithium-based cells; they may explode or catch fire if mishandled. Don't use this schematic until you know exactly what you're doing and how   the values of critical components affect its operation.







simulate this circuit &ndash; Schematic created using CircuitLab