1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950 |
- import FileManager from "./base/file-manager";
- export default class ImageManager {
- constructor(page) {
- this._page = page;
-
- this._page.imageClickEvent = function (e) {
- wx.previewImage({
- current: e.currentTarget.dataset.url,
- urls: [e.currentTarget.dataset.url]
- })
- }
- }
-
- sendOneMsg({ type, content, duration }) {
- const temp = this._page.imOperator.createNormalChatItem({
- type,
- content,
- duration
- });
- this._page.UI.showItemForMoment(temp, (itemIndex) => {
- this._page.sendMsg({
- content: this._page.imOperator.createChatItemContent({ type, content, duration }),
- itemIndex,
- success: (msg) => {
-
- }
- });
-
- });
- }
- }
|